Question Detail
Question
What will be the output of the following code snippet from the 'Classroom Activity'?
Correct Answer
Option B is the correct answer.
Detailed Explanation
Page 16, 'Classroom Activity' lists: '2. age = 14; if age >= 18: print("Adult")'. Here,
age is 14. The condition age >= 18 (14 >= 18) is False. Since there is no else block, nothing is printed.
Hint
Check if the condition for printing 'Adult' is met given the value of 'age'.