7
AssignmentMultiple Choice

Conditional Statements

Question 7 • VA-Information Technology Fundamentals B

You have been asked to write some code for a teacher. The code will print encouraging statements for students who do not have an A in the class. The exact message will depend on whether the student has a B, C, D, or F in the class.You will need an

Answer
A
Else statement.
B
Elif statement.

Explanation

An elif statement lets the code check several different grade conditions, such as B, C, D, or F, after the initial if condition. An else statement handles one remaining case without checking which specific grade it is. The correct choice is “Elif statement.”

AI-written and checked against the verified answer.

Previous
Next