------------控制流-----------
'''
1、什么是流程:做某一件事情就叫做流程
2、流程分类
2.1顺序结构:代码从上往下执行
2.2选择结构:代码根据条件选择性得执行
2.3循环结构:重复做一件事情
'''
# 2.2、选择结构
# 2.2.1:单if语句
# 实例:
test_num=9
if test_num>=9:
print("test_num>=9")
print("test_num<9")
# 2.2.2:标准得if else语句
# 实例:
test_num=9
if test_num>=9:
print("test_num>=9")
else:
print("test_num<9")
# 2.2.3:复合if elif else语句 elif:继续判断
# 实例1:
test_num=9
if test_num>9:
print("test_num>9")
elif test_num==9:
print("test_num=9")
else:
print("test_num<9")
# 实例2:
test_num=9
if test_num>=9:
print("test_num>=9")
if test_num==9:
print("test_num=9")
elif test_num==9:
print("test_num=9")
else:
print("test_num!=9")
else:
print("test_num<9")