2018年6月4日
摘要: import turtle turtle.speed(10) colors =['#EE7600','#FF3E96','#00E5EE','#00EEEE','#00CED1','#EE0000','#00B2EE','#FF4500'] for i in range(200): turtle.p 阅读全文
posted @ 2018-06-04 16:05 木匀…… 阅读(79) 评论(0) 推荐(0)
  2018年5月28日
摘要: fr = open('221.txt',mode='r',encoding='utf-8') plainText = fr.read() print('明文:'+plainText) print('密文:',end='') for c in plainText: print(chr(ord(c)+3 阅读全文
posted @ 2018-05-28 16:08 木匀…… 阅读(180) 评论(0) 推荐(0)
  2018年5月21日
摘要: stuNum = '201709090053' print('年级是:'+stuNum[0:4]) print('专业编号是:'+stuNum[4:9]) print('序号是:'+stuNum[-3:]) stuNum = '440111199810260216' print('所在省市:'+stuNum[0:2]) print('所在地区:'+stuNum[2:4]) print('所在县... 阅读全文
posted @ 2018-05-21 16:00 木匀…… 阅读(128) 评论(0) 推荐(0)
  2018年5月14日
摘要: import turtle while True: turtle.forward(100) turtle.right(190) if abs(turtle.pos())<1: break turtle.done() 阅读全文
posted @ 2018-05-14 15:07 木匀…… 阅读(107) 评论(0) 推荐(0)
  2018年5月12日
摘要: import turtle turtle.forward(100) turtle.right(144) turtle.forward(100) turtle.right(144) turtle.forward(100) turtle.right(144) turtle.forward(100) turtle.right(144) turtle.forward(100) turtle.ri... 阅读全文
posted @ 2018-05-12 11:22 木匀…… 阅读(114) 评论(0) 推荐(0)
  2018年5月4日
摘要: myNum=20 print('猜字游戏练练玩\n') while True: guess=int(input('请输入一个数字 :')) if guess>myNum: print('猜大了') elif guess<myNum: print('猜小了') else: print('你终于猜对了') ... 阅读全文
posted @ 2018-05-04 15:45 木匀…… 阅读(66) 评论(0) 推荐(0)
  2018年4月28日
摘要: while True: a = input('1:摄氏温度转为华氏温度请按\n2:华氏温度转为摄氏温度请按\n3:退出\n') if a =='1': c = float(input('请输入摄氏温度:')) f = c*9/5+32 print('{:.2f}摄氏温度转为华氏温度为:{:.2f}\ 阅读全文
posted @ 2018-04-28 19:43 木匀…… 阅读(115) 评论(0) 推荐(0)
  2018年4月23日
摘要: a=input('摄氏温度转换为华氏温度请按1\n华氏温度转换为摄氏温度请按2\n') if a=='1': #摄氏℃=5/9 (°F-32) #1.输入 f=float(input('请输入华氏温度:')) #2.计算 c=5/9*(f-32) #3.输出 print('{:.2f}华氏温度转换为摄氏温度为;{:.2f}'.format(f,c... 阅读全文
posted @ 2018-04-23 15:57 木匀…… 阅读(95) 评论(0) 推荐(0)
摘要: #用户输入摄氏温度 celsius=float(input('输入摄氏温度:')) #计算华氏温度 fahrenheit=(celsius*9/5)+32 #f=c*9/5+32 #向用户输出华氏温度 print('{:.2f}摄氏温度转为华氏温度为{:.2f}'.format(celsius,fahrenheit)) #摄氏℃=5/9 (°F-32) #1.输入 f=floa... 阅读全文
posted @ 2018-04-23 15:54 木匀…… 阅读(82) 评论(0) 推荐(0)
摘要: #摄氏℃=5/9 (°F-32) #1.输入 f=float(input('请输入华氏温度:')) #2.计算 c=5/9*(f-32) #3.输出 print('{:.2f}华氏温度转换为摄氏温度为;{:.2f}'.format(f,c)) #用户输入摄氏温度 celsius=float(input('输入摄氏温度:')) #计算华氏温度 fahrenheit=... 阅读全文
posted @ 2018-04-23 15:51 木匀…… 阅读(93) 评论(0) 推荐(0)