Last Updated on October 18, 2019 by InfraExam

## PCAP – Programming Essentials in Python Quizzes Module 1 Test Answers

1. ### The \n digraph forces the print() function to:

• output exactly two characters: \ and n
• duplicate the character next to the digraph
• stop its execution
• break the output line
2. ### The meaning of the keyword parameter is determined by:

• its position within the argument list
• its value
• its connection with existing variables
• the argument’s name specified along with its value

• 20E12.8
• 20.12E8
• 20.12*10^8
• 20.12E8.0

• decimal
• binary
• octal
5. ### The ** operator:

• performs exponentiation
• performs duplicated multiplication
• does not exist
• performs floating-point multiplication

### 1 / 1

• is equal to 1
• cannot be evaluated
• cannot be predicted
• is equal to 1.0
7. ### Only one of the following statements is false – which one?

• the result of the / operator is always an integer value
• the right argument of the % operator cannot be zero
• the ** operator uses right sided binding

### is equal to:

• 0.0
• 4.5
• 0
• 0.16666666666666666

• true
• tRUE
• True
• TRUE
10. ### The print() function can output values of:

• any number of arguments (excluding zero)
• just one argument
• any number of arguments (including zero)
• not more than five arguments

• 1 2
• 2 1
• 1 1
• 2 2

• 6
• 24
• 4
• 2

### x=int(input()) y=int(input()) x=x//y y=y//x print(y)

• 2.0
• the code will cause a runtime error
• 4.0
• 8.0

### x=int(input()) y=int(input()) x=x/y y=y/x print(y)

• the code will cause a runtime error
• 8.0
• 4.0
• 2.0

• 3
• 2
• 1
• 4

• 36
• 18
• 333333
• 666

• 1 1 1
• x y z
• 1*1*1
• x*y*z

### x = 2 + 3 * 5. print(X)

• the snippet will cause an execution error
• 17
• 17.0
• 25.0

• 17
• 17.5
• 8.5
• 8

• 4
• 2
• 24
• 6