C-18-Q043mediumsingle_mcq
Which Python comparison operator allows the counter value 3 itself to enter the loop body in while (count<=3)?
Which Python comparison operator allows the counter value 3 itself to enter the loop body in while (count<=3)?
- a
< - b
<= - c
== - d
>=
ব্যাখ্যা
The <= operator means "less than or equal to," so the loop body executes for every value up to and including 3. With < alone, the counter would stop before reaching 3, excluding it from the loop.