摘要:
判断salary是不是数字,假如是数字就正常执行,不是数字就打印must input digit的提示,并且退出: must input digit 阅读全文
摘要:
sz=1 while sz<=9: sec = 1 while sec <= sz: print(str(sec),"*",str(sz),"=",sec*sz," ",end="") sec += 1 print() sz += 1输出: 1 * 1 = 1 1 * 2 = 2 2 * 2 = 4 1 * 3 = 3 2 * 3 = 6 3 * 3 = 9 1 * 4 = 4 2 * 4 = 8 阅读全文