Est-il correct d'écrire du code qui dépend de cela ...
>>> 1 is None
False
>>> 1 is None and b
False
>>> b and 1 is None
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
NameError: name 'b' is not defined
Recommended Posts