1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
elena-s [515]
3 years ago
15

Is_sum_odd that takes a non-negative integer number as parameter and returns true if the sum of individual digits is odd, false

otherwise.
Computers and Technology
1 answer:
lara31 [8.8K]3 years ago
6 0
Make sure that you understand how addDigits( number, base ) works!

```
#!/usr/bin/python

import sys


def addDigits( number, base ):
    if( number ):
        return( addDigits( number // base, base ) + ( number % base ) )
    else:
        return( 0 )


def wrapper( number, base=10 ):
    if( ( addDigits( number, base ) ) % 2 ):
        return True
    else:
        return False


if( __name__ == "__main__" ):
    if( len( sys.argv ) != 2 ):
        sys.stderr.write( "usage: " + sys.argv[ 0 ] + " <integer>\n" )
        exit( 127 )

    print wrapper( int( sys.argv[ 1 ] ) )
```

You might be interested in
6. Which of the following options is used to view a computer's memory properties?
pentagon [3]
There is an option used to vew a computer's memory properties by just simply opening your My computer directory. There you can see different names of your hard drive, there you choose what hard drive you want to view by just right clicking it and choosing properties. There you will see it's memory space.
3 0
4 years ago
When users talk about font size,
koban [17]

Answer:

The answer is 10......

4 0
3 years ago
Read 2 more answers
Which setting on a profile makes a tab NOT accessible in the All App Launcher or visible in any app, but still allows a user to
Levart [38]

Answer:

freezer

Explanation:

you can freeze your application and it won't show on your launcher till you unfreeze it

5 0
3 years ago
What should you wear during lab investigations to protect your eyes?
vladimir2022 [97]

Answer:

Goggles

Explanation:

If  a chemical splashes on goggles it on hurt you.

3 0
3 years ago
What is TRUE about the following array?
mr Goodwill [35]
<span>d. someVals[1] has the value of 4</span>
3 0
4 years ago
Other questions:
  • Debuted by the Lumiere Brothers, a hand cranked device that showed moving pictures to an audience​
    7·1 answer
  • A soldier white line down the center of a two lane road indicates
    5·1 answer
  • Special characters that display on the screen but do not print are called _____________
    15·1 answer
  • Acts as a platform on which application software runs?
    6·1 answer
  • A student has created a Book class. The class contains variables to represent the following.An int variable called pages to repr
    11·1 answer
  • Describe some ways that you personally use information technologies differently than you did just a few years ago
    11·1 answer
  • Name the default Package of java<br>​
    8·2 answers
  • What is computer science ​
    5·1 answer
  • I WILL GIVE MOST BRAINLY
    13·1 answer
  • How does the technology affect you daily living? Give situations where you use technology and how it helped you.​
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!