摘要: fr = open('qcj.txt',mode='r',encoding='utf-8') qcj = fr.read() print('明文:'+qcj) print('密文:',end='') fw = open('cipherText.txt',mode='a',encoding='utf-8') for c in qcj: print(chr(ord(c)+3),end='... 阅读全文
posted @ 2018-05-28 16:37 邱楚峻 阅读(104) 评论(0) 推荐(0) 编辑
摘要: stuNum='201709090046' print('年级是:'+stuNum[0:4]) print('专业编号是:'+stuNum[4:9]) print('序号是:'+stuNum[-3:]) stuNum='441900199904206500' print('广东省:'+stuNum[0:4]) print('东莞市:'+stuNum[4:6]) print('... 阅读全文
posted @ 2018-05-21 16:09 邱楚峻 阅读(98) 评论(0) 推荐(0) 编辑
摘要: import turtle while True: turtle.forward(110) turtle.right(190) if abs(turtle.pos())<1: break turtle.done() 阅读全文
posted @ 2018-05-14 15:29 邱楚峻 阅读(116) 评论(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, 110)... 阅读全文
posted @ 2018-05-14 15:25 邱楚峻 阅读(205) 评论(0) 推荐(0) 编辑
摘要: import turtle turtle.circle(23) turtle.circle(66) import turtle turtle.circle(33) turtle.up() turtle.goto(0,-33) turtle.down() turtle.circle(66) turtle.done() myNum=13 print('猜字游戏\n') while Tr... 阅读全文
posted @ 2018-05-07 16:02 邱楚峻 阅读(162) 评论(0) 推荐(0) 编辑
摘要: >>> a=input('请输入一个数字') 请输入一个数字2 >>> b=input('请输入另一个数') 请输入另一个数3 >>> sum1=int(a)+int(b) >>> print('二数之和是:{}'.format(sum1)) 二数之和是:5 >>> a=input('请输入摄氏温度') 请输入摄氏温度55 >>> sum1=int(a)*9/5+32 >>> print('华氏.. 阅读全文
posted @ 2018-04-23 15:41 邱楚峻 阅读(85) 评论(0) 推荐(0) 编辑
摘要: >>> name1=input('请输入一个名字') 请输入一个名字111 >>> name2=input('请输入一个名字') 请输入一个名字222 >>> vehicle=input('请输入一种车子') 请输入一种车子333 >>> print('喝醉的{}和{}被{}撞倒了'.format(name1,name2,vehicle)) 喝醉的111和222被333撞倒了 >>> 阅读全文
posted @ 2018-04-16 16:36 邱楚峻 阅读(133) 评论(0) 推荐(0) 编辑