What will be the output of the following Python code?

ICSE Class 10 Robotics & AI PYQ · 2026 Paper · Section A

2(viii)1 Mark · 2026 · Section A · 2026 Paper

What will be the output of the following Python code?

a = 5
b = 3
print(a > b and b < 3)
Show SolutionHide Solution↓
False

Given: a = 5, b = 3

Evaluate the expression: a > b and b < 3

  • a > b → 5 > 3 → True
  • b < 3 → 3 < 3 → False

Now, True AND False → False (The AND operator returns True only when both conditions are True, otherwise, it returns False.)

Hence, the output is False.

← Previous questionNext question →

Browse the free Robotics & AI sample bank