$ ./guess_the_languageProblem Solving — predict the output
Problem Solving — predict the output · medium · #31

What is printed?

print(True + True)
  1. True
  2. 1
  3. TrueTrue
  4. 2
Booleans act as integers, so True + True is 2.
Play Problem Solving ▸