Font size
WorksheetsUnit 2: Review
Total questions: 17
Worksheet time: 9mins
What is the value of 15 / 12?
1
1.25
1.5
1.3
What is the value of 15 // 12?
1
1.25
1.5
3
What is the value of 15 % 12?
1
1.25
1.5
3
What is the data type of 'this is what kind of data'?
Character
Integer
Float
String
What is printed when the following statements execute?
Nothing. Run time Error
Thursday
32.5
19
What is printed when the following statements execute?
<class 'str'>
<class 'int'>
<class 18>
18
What is the value of the following expression:
14
24
3
3.667
After the following statements, what are the values of x and y?
A. x is 15 and y is 15
B. x is 22 and y is 22
C. x is 15 and y is 22
D. x is 22 and y is 15
Given the following code segment, what will be printed?
A. The address is street
B. The address is 125 Main Street
C. It won't execute
D. 500 Gentryside Dr
Given the following code segment, what will be printed?
A. Derrick has 4 friends
B. name has 4 friends
C. name has friends friends
D. There will be an error
Given the following code segment, what will be printed?
A. Mariah has 2 pets
B. name has 2 pets
C. Mariah has pets pets
D. There will be an error
What is the data type of the value 3.14?
Integer
String
Float
Boolean
What is the result of 18 // 5?
3.6
3.5
3
4
What is the data type of the value True?
Float
Boolean
String
Integer
Which of the following is a valid Boolean value in Python?
True
"False"
yes
1.0
What is the result of the expression 7 % 3?
0
3
2
1
What is the data type of the value 42?
Float
String
Integer
Boolean
