📜  python代码示例中的布尔含义

📅  最后修改于: 2022-03-11 14:45:15.118000             🧑  作者: Mango

代码示例1
# Booleans are simply just True and False
# Example: The "true" below is considerd as a bool.
x = True
print(x) # << This will print "True" because we have set x
# to True. If we change the value of x to False, it would print false.
# Keep in mind the the T in True and the F in False ALWAYS have to be capital.
# Or else it won't work.