Table of Contents
Mastering Python If-Else Statements: A Complete Guide
🔒 Please log in to unlock this course.
MCQ Section
MCQ 1
What will be the output after the following statements? x = 80 if x = 75: print('true') elif x =…
Locked. Enroll to open this MCQ.
MCQ 2
What will be the output after the following statements? a = True b = False c = 'a' if (b == 0) else…
Locked. Enroll to open this MCQ.
MCQ 3
What will be the output after the following statements? x = 99 if x = 100: print('true') elif x >=…
Locked. Enroll to open this MCQ.
MCQ 4
What will be the output after the following statements? x = 68 if x = 25: print('true') elif x =…
Locked. Enroll to open this MCQ.
MCQ 5
What will be the output after the following statements? x = 5 if x > 15: print('yes') elif x == 15:…
Locked. Enroll to open this MCQ.
MCQ 6
What will be the output after the following statements? x = 70 if x = 100: print('true') elif x =…
Locked. Enroll to open this MCQ.
MCQ 7
What will be the output after the following statements? a = True b = False c = 5 if (a == 1) else b…
Locked. Enroll to open this MCQ.
MCQ 8
What will be the output after the following statements? x = 30 if x = 75: print('true') elif x =…
Locked. Enroll to open this MCQ.
MCQ 9
What will be the output after the following statements? x = 50 if x > 10 and x < 15: print('true')…
Locked. Enroll to open this MCQ.
MCQ 10
What will be the output after the following statements? x = 25 if x > 10 and x = 15 and x < 25:…
Locked. Enroll to open this MCQ.
MCQ 11
What will be the output after the following statements? x = 8 if x > 8: print(20) else: print(10)
Locked. Enroll to open this MCQ.
MCQ 12
What will be the output after the following statements? x = 25 if x >= 10 and x = 15 and x = 25 and…
Locked. Enroll to open this MCQ.
MCQ 13
What will be the output after the following statements? x = 20 if x = 75: print('true') elif x =…
Locked. Enroll to open this MCQ.
MCQ 14
What will be the output after the following statements? x = 27 if x < 25: print(x) else: pass
Locked. Enroll to open this MCQ.
MCQ 15
What will be the output after the following statements? x = 25 if x > 10 and x < 15: print('true')…
Locked. Enroll to open this MCQ.
MCQ 16
What will be the output after the following statements? x = 40 y = 25 if x + y >= 100:…
Locked. Enroll to open this MCQ.
MCQ 17
What will be the output after the following statements? x = 15 if x > 15: print(0) elif x == 15:…
Locked. Enroll to open this MCQ.
MCQ 18
What will be the output after the following statements? x = 15 if x > 10 and x 15 and x < 25:…
Locked. Enroll to open this MCQ.
MCQ 19
What will be the output after the following statements? x = 60 if x = 75: print('true') elif x =…
Locked. Enroll to open this MCQ.
MCQ 20
What will be the output after the following statements? x = 40 if x > 10: print(20) elif x == 40:…
Locked. Enroll to open this MCQ.
MCQ 21
What will be the output after the following statements? x = 7 if x > 5: print(20)
Locked. Enroll to open this MCQ.
Get Python Programming Language updates by email
Short, practical lessons and course updates from Rumman Ansari. No spam.