06 2018 档案

摘要:#1, letFile = open('let.txt','r') letTest = letFile.read() letFile.close() print(letTest) #2, print(letTest.replace(',',' ')) print(letTest.replace("' 阅读全文
posted @ 2018-06-20 21:35 王滢 阅读(215) 评论(0) 推荐(0)
摘要:def hanoi(n,a,b,c): if n==1: print(n,a+'->'+c) else: hanoi(n-1,a,c,b) print(n,a+'->'+c) hanoi(n-1,b,a,c) hanoi(2,'A','B','C') 阅读全文
posted @ 2018-06-13 21:20 王滢 阅读(190) 评论(0) 推荐(0)
摘要:l = ['AA','BB','CC'] l.append('BB') l.pop() print(1) t = ('AA','BB','CC') scores = [88,99,100] d = {'AA':88,'BB':99,'CC':100} d['BB'] = 95 d['Want'] = 阅读全文
posted @ 2018-06-06 21:31 王滢 阅读(186) 评论(0) 推荐(0)