一、
print(1 or 1 > 4) # 1 (从左到右1为True就结束了)
print(1 > 1 or 3) # 3
print(3 > 1 or 3 or 3 > 4 and 5) # True
# x or y 如果 x为真,则值为x,否则为y
print(3 or 0) # 3
print(0 or 3) # 3
# x and y 如果 x 为真,则值为 y,否则为 x
print(3 and 0) # 0
print(0 and 3) # 0
二、
非空字符串的bool值都是True
‘’空字符串为False(无空格)
s = 'shili'
s1 = 'li'
s2 = 'xu'
s3 = '1'
s4 = ''
print(bool(s)# True
print(bool(s1)) # T
print(bool(s2)) # T
print(bool(s3)) # T
print(bool(s4)) # FALSE
三、1、
bool---->str值
a = str(True) #'True'
b = str(False) #'False'
print(a,type(a))
print(b,type(b))