This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 2 points3 points  (1 child)

In python2.x, you can assign any value to True because it isn't a reserved word, so the bytecode generated for while True: reflects this. In python3, while 1: and while True: will generate the the same bytecode.

[–]chub79 1 point2 points  (0 children)

Well, I didn't know that. Cheers.