立即學習:https://edu.csdn.net/course/play/26099/322895?utm_source=blogtoedu
'''
成員運算符:in not in
身份運算符:is is not
三目運算符:if else
優先級:資料網站:http://c.biancheng.net/view/2190.html
'''
# 成員運算符
names = ['老敖', '老豬', '老孫', '老陳', '老沙']
print('老唐' in names) # 結果 False
print('老敖' in names) # 結果 True
print('老唐' not in names) # 結果 True
print('老敖' not in names) # 結果 False
other = '1425aaddderer'
print('4' in other) # 結果 True
# 身份運算符:is not is
a = '2asss'
b = '2asss'
print(a == b) # 判斷值 結果:True
print(a is b) # 判斷內存位置 結果:True--因爲在一個文件裏一次編譯,只開闢了一個內存位置 所以爲True
#三目運算符:if else
# 格式:結果1(真) if 條件 else 結果2 (假)(相當於 java和net中的 條件?結果1(真):結果2(假))