We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0bb90de commit b3abff7Copy full SHA for b3abff7
what-is-true.md
@@ -203,7 +203,8 @@ if value is None: ... # best
203
## Summary
204
205
- `if thing:` does the same thing as `if bool(thing):`. This also
206
- works with while loops and most other things.
+ works with while loops and most other things that are usually used
207
+ with Booleans.
208
- `bool()` of most things is True, but `bool()` values of None,
209
zero and most empty things are False.
210
- Use `is` and `is not` when comparing to None, `==` and `!=` when
0 commit comments