Single Choice Moderate

QWrong condition logic causes:

ID: #25944 MCQ Quiz - Class 8 - Decision Control Structure 3 views
Question Info
#25944Q ID
ModerateDifficulty
MCQ Quiz - Class 8 - Decision Control StructureTopic

Choose the Best Option

Click any option to instantly check if you're correct.

  • A Logical error
  • B Compile error
  • C Runtime always
  • D None
Correct Answer

Explanation

Correct Answer Explanation:

If your condition is logically wrong (e.g., > instead of <), the code compiles but produces wrong output — a logical error.

Why the other options are incorrect:

  • Option B: The syntax is fine; compile error doesn't happen.
  • Option C: Not necessarily runtime; depends on logic.
  • Option D: There is definitely an error.

Share This Question

Challenge a friend or share with your study group.