Built-in Constants
False — negative Boolean singleton
False is the negative value of bool. Empty collections, numeric zeros and None also fail truth tests, but they are not the False object. A string containing the word False is truthy because it is nonempty. False compares and hashes like the integer 0, so mapping and set keys cannot distinguish these two equal values. Arithmetic may produce an int rather than a Boolean. For ordinary condition checks, use not value; for an API that distinguishes the exact Boolean False from missing or zero, use identity. False cannot be rebound in Python source.
Formal Syntax & Structure
python syntaxpython
FalseReturn Value
bool
The negative Boolean singleton.
Working Example
Example Snippetpython
for value in (False, 0, None, "False"): print(repr(value), bool(value), value is False)flags = {False: "off", 0: "updated"}print(len(flags), flags[False])