python中的控制語句

python基礎之-控制語句 1.分支結構 if...else... #語法: #if 條件: #  if語句塊 #else:   #  else語句 s = 7 if s > 1 and s<6: print('{}在1-6之間'.format(s)) else: print('{}不在1-6之間'.format(s)) if...elif...else... # if 條件
相關文章
相關標籤/搜索