2018年6月4日

摘要: import turtle turtle.speed(12) colors=['red','#9B30FF','#87CEFF','#76EE00','#EEB422','orange'] for i in range(233): turtle.pencolor(colors[i%6]) turtl 阅读全文
posted @ 2018-06-04 16:11 罗泽皓 阅读(86) 评论(0) 推荐(0) 编辑

2018年5月28日

摘要: fr = open('iii.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:28 罗泽皓 阅读(96) 评论(0) 推荐(0) 编辑

2018年5月21日

摘要: stuNum='201709080065' print('年级是:'+stuNum[0:4]) print('专业编号是:'+stuNum[4:9]) print('序号是:'+stuNum[-3:]) stuNum ='440104199704243419' print('所在省市:'+stuNum[0:2]) print('所在地区:'+stuNum[2:4]) print('所... 阅读全文
posted @ 2018-05-21 16:09 罗泽皓 阅读(108) 评论(0) 推荐(0) 编辑

2018年5月14日

摘要: import turtle while True: turtle.forward(100) turtle.right(77) if abs(turtle.pos())<1: break 阅读全文
posted @ 2018-05-14 15:22 罗泽皓 阅读(101) 评论(0) 推荐(0) 编辑
摘要: import turtle # 设置初始位置 turtle.penup() turtle.left(90) turtle.fd(200) turtle.pendown() turtle.right(90) # 花蕊 turtle.fillcolor("red") turtle.begin_fill() turtle.circle(10, 180) turtle.circle(25, ... 阅读全文
posted @ 2018-05-14 15:12 罗泽皓 阅读(175) 评论(0) 推荐(0) 编辑

2018年5月7日

摘要: myNum = 333 print('猜数字游戏\n') while True: guess=int(input('请输入一个数,大于0小于1000:')) if guess > myNum: print('猜大了') elif guess < myNum: print('猜小了') else: print('恭喜... 阅读全文
posted @ 2018-05-07 16:04 罗泽皓 阅读(98) 评论(0) 推荐(0) 编辑

2018年4月23日

摘要: >>> f=float(input('请输入华氏温度:')) 请输入华氏温度:30 >>> c=5/9*(f-32) >>> print('{:.2f}华氏温度转换为摄氏温度为:{:.2f}'.format(f,c)) 30.00华氏温度转换为摄氏温度为:-1.11 >>> c=float(input('请输入摄氏温度:')) 请输入摄氏温度:30 >>> f=c*9/5+32 >>> pr... 阅读全文
posted @ 2018-04-23 15:31 罗泽皓 阅读(177) 评论(0) 推荐(0) 编辑

2018年4月16日

摘要: >>> name1=input("请输出一个名字:") 请输出一个名字:秦嘉耀 >>> name2=input("请输出一个名字:") 请输出一个名字:李均捷 >>> vehicle=input("请输出一个名字:") 请输出一个名字:紫爵 >>> print('刚洗完澡的{}被开着{}的{}溅了一身水'.format(name1,vehicle,name2)) 刚洗完澡的秦嘉耀被开着紫爵的李均... 阅读全文
posted @ 2018-04-16 16:33 罗泽皓 阅读(122) 评论(0) 推荐(0) 编辑

导航