🎙 Free live masterclass · Sun, 29 Nov, 7:00 pm IST · Java Full Stack roadmap Register free →
Skills101
← Quiz: Python Conditions: all 13 questions

Quiz: Python Conditions · Question 9 of 13

What does this print? (code)

What does this print?

marks = 85
if marks >= 40:
    print("Pass")
elif marks >= 80:
    print("Distinction")
  1. A.Pass
  2. B.Distinction
  3. C.Pass Distinction
  4. D.Nothing
Answer & explanation

Correct answer: Pass

The first true condition wins, and 85 >= 40 is checked first. Put the stricter check (>= 80) first.

Can you get the rest right without peeking?

Take the timed Quiz: Python Conditions quiz free. Pass it to earn XP and count towards your certificate.

Start the quiz →