5.1 if语句 没什么好说,if语句语法如下: if expression: expr_true_suit 5.1.1多重条件表达式 单个if语句可以通过布尔操作符and,or,not实现多重条件判断或否定判断. if not warn and (system_load>=10): print 'WARNING:LOSING RESOURCE' warn+=1 5.2 else 语句 如果if条件为假程序将执行else后的语句. if expression: expr_true_suit el…
条件语句 if # if if condition then command fi # if else if condition then command else command fi # if elif if condition then command elif condition then command else command fi 需要注意的是 elif下面还有个then for # 第一种表达方式 for v in item1 item2 item3 itemN do comma…