$ ./guess_the_languageProblem Solving — predict the output
Problem Solving — predict the output · easy · #239

What is the output?

x = 5
print(1 < x < 3, 1 < x > 3)
  1. True True
  2. False True
  3. False False
  4. True False
Python chains comparisons: 1 < x < 3 means 1 < x and x < 3 (False), and 1 < x > 3 means 1 < x and x > 3 (True).
Play Problem Solving ▸