Exam | Actual Questions and Answers Latest
Updated (Graded A+)
Part 1
Which of the following objects is immutable?
A. Dictionary
B. List
C. Set
D. Tuple
Answer Point Value: 1.0 points
Answer Key: D
Which of the following objects is mutable?
A. Float
B. String
C. Frozen Set
D. Boolean
E. None of the Above
Answer Point Value: 1.0 points
Answer Key: E
,In Python, everything is an object.
True
False
Answer Point Value: 1.0 points
Answer Key: True
When creating the variable, b = 10, b contains the value 10.
True
False
Answer Point Value: 1.0 points
Answer Key: False
An object whose internal data can be changed is called a object.
Answer Point Value: 1.0 points
Answer Key: mutable
Fill in the command such that the type of variable x is printed.
print( )
Answer Point Value: 1.0 points
Answer Key: type(x)
Which of the following is a valid python comment?
A. // This is a comment.
B. $ This is a comment.
C. @ This is a comment.
D. # This is a comment.
Answer Point Value: 1.0 points
Answer Key: D
, The loop:
for i in range(17, 42):
print(i)
will print out values starting with and ending with
Answer Point Value: 3.0 points
Answer Key: 25, 17, 42
The loop:
for i in range(17, 42, 3):
print(i)
will print out values starting with and ending with
Answer Point Value: 3.0 points
Answer Key: 9, 17, 41
What is the type of variable x given: x = string(float(int(5)))
A. String
B. Integer
C. Float
D. x is not defined
Answer Point Value: 1.0 points
Answer Key: D
When trying to call a variable that does not exist, you will receive a
Error
Answer Point Value: 1.0 points
Answer Key: Name