The Python Oracle

Why does (1 in [1,0] == True) evaluate to False?

Become part of the top 3% of the developers by applying to Toptal https://topt.al/25cXVn

--

Music by Eric Matyas
https://www.soundimage.org
Track title: Realization

--

Chapters
00:00 Question
01:46 Accepted answer (Score 199)
02:25 Thank you

--

Full question
https://stackoverflow.com/questions/9284...

Question links:
[this question]: https://stackoverflow.com/questions/9201...
[Why does the expression 0 < 0 == 0 return False in Python?]: https://stackoverflow.com/questions/6074...

Accepted answer links:
[Python language documentation]: http://docs.python.org/reference/express...

--

Content licensed under CC BY-SA
https://meta.stackexchange.com/help/lice...

--

Tags
#python #syntax #operatorprecedence

#avk47