摘要: while True: a = int(input('摄氏转华氏请按1 华氏转摄氏请按2 退出请按3')) if a==1: c = float(input('请输入摄氏温度:')) f = c*9/5+32 print('摄氏{:.2f}的华氏为{:.2f}\n'.format(c,f)) eli 阅读全文
posted @ 2018-04-25 21:33 CarmenWong 阅读(233) 评论(0) 推荐(0) 编辑
摘要: a = input('1.摄氏转华氏 2.华氏转摄氏') if a == '1': c = input('请输入摄氏温度:') f = float(c)*9/5+32 print('{}摄氏温度转为华氏温度是{}'.format(c,f)) else: f = float(input('请输入华氏温度:')) c = 5/9*(f-32) prin... 阅读全文
posted @ 2018-04-25 20:47 CarmenWong 阅读(281) 评论(0) 推荐(0) 编辑