Important MCQ

Exactly how many blocks of an if-else execute?

Q.Exactly how many blocks of an if-else execute?

A) Two
B) Three
C) Zero
D) One
Correct Answer:
Option D
Detailed Explanation:
D) One is correct. An if-else statement makes a two-way decision: the if block runs when the condition is true, otherwise the else block runs. Exactly one branch is selected.