Python - MCQ

Multiple Choice Questions


Share with a Friend

 

Python - Multiple Choice Questions (MCQ) - Python Operators and Control Flow Statements - Set 11

16. Is for loop possible without range() in Python 
A). Yes
B). No
C). Maybe
View Answer
Correct: A



17. Python provides keywords to perform logical operation, Select correct keywords from following 
A). assert
B). continue
C). import
D). break
E). await
F). pass
G). else
View Answer
Correct: B, D, F, G


18. Which code is correct for this output? 

A). Option 1

B). Option 2
C). Both above Options
D). None of the above
View Answer
Correct: C



19. What is the result of print(type([]) is list)
A). TRUE
B). FALSE
View Answer
Correct: A


20. What is the output of the following variable assignment

x = 75
def myfunc():
    x = x + 1
    print(x)

myfunc()
print(x)
A). Error
B). 76
C). 1
D). None
View Answer
Correct: A



 
 
 
   
   
   
UltraInfo Technologies
ITDeveloper