Does Python actually contain a Boolean value? I know that you can do:
checker = 1 if checker: #dostuff
But I\'m quite pedantic and enjo
Yes, there is a bool data type (which inherits from int and has only two values: True and False).
bool
int
True
False
But also Python has the boolean-able concept for every object, which is used when function bool([x]) is called.
boolean-able
bool([x])
See more: object.nonzero and boolean-value-of-objects-in-python.