摘要: from turtle import* def square(size=50, rgb = 'blue'): pencolor(rgb) for i in range(4): fd(size) left(90) def main(): setup(800, 600) speed(0) for i i 阅读全文
posted @ 2021-06-11 17:30 jsuox 阅读(22) 评论(1) 推荐(0) 编辑
摘要: class StudentDoc: def __init__(self,studentnumber,name,major,point): self._studentnumber = studentnumber self._name = name self._major = major self._p 阅读全文
posted @ 2021-05-31 22:38 jsuox 阅读(26) 评论(1) 推荐(0) 编辑
摘要: 6.实验任务6:综合应用(1)——分数文件处理 with open('data6_1.txt','r',encoding='utf-8') as f: a=[] for line in f.readlines(): m=line.strip().split() a.append(m) a.sort( 阅读全文
posted @ 2021-05-16 21:29 jsuox 阅读(63) 评论(1) 推荐(0) 编辑
摘要: 实验任务一 x = list(range(10)) print('整数输出1:', end = '') for i in x: print(i, end = ' ') print('\n整数输出2:', end = '') for i in x: print(f'{i:02d}',end = '-' 阅读全文
posted @ 2021-04-22 23:54 jsuox 阅读(54) 评论(1) 推荐(0) 编辑
摘要: x1,y1=1.2,3.57 x2,y2=2.26,8.7 print('{:-^40}'.format('输出1')) print('x2={},y1={}'.format(x1,y1)) print('x2={},y2={}'.format(x2,y2)) print('{:-^40}'.for 阅读全文
posted @ 2021-04-06 09:57 jsuox 阅读(53) 评论(1) 推荐(0) 编辑
摘要: 1、实验任务一 task1 print('hey, u') print('hey', ' u') x = 1 y = 2 z = 3print(x, y, z)print('x = %d, y = %d, z = %d' %(x,y,z)) print('x = {}, y = {}, z = {} 阅读全文
posted @ 2021-04-02 17:14 jsuox 阅读(45) 评论(2) 推荐(2) 编辑