to my knowledge, if you input any text it will return true and if you input nothing it will return false. if it's possible without if statements, how do i check if they inputted 'True' or 'False (/ '1' or '0') when im doing 'bool(input("Input True or False ")'.

you are viewing a single comment's thread
view the rest of the comments
[+] -8 points 2 years ago (2 children)

You can use eval(input). It converts string to whatever the actual content is.

  • source
  • parent
  • hideshow 4 child comments