代码改变世界

随笔档案-2019年07月

python3--basic3

2019-07-13 00:15 by yanux, 364 阅读, 收藏,
摘要: "D:\Program Files\Python37\python.exe" D:/code/python3/homework1/money_cocks.pyThe number of cock, hen, chicken is: 4 12 84The number of cock, hen, ch 阅读全文

python3--basic2

2019-07-12 23:46 by yanux, 219 阅读, 收藏,
摘要: # 1,2,3,4,5,6,7,8,9 print all the non-duplicated 2 bits numbers consist of these numbers; # print the counter of the numbers # L = [] # for i in range(1,10,1): # for j in range(1,10,1): # ... 阅读全文

python3--basic1

2019-07-12 23:10 by yanux, 248 阅读, 收藏,
摘要: L1 = [11, 22, 33,'a', 'b',(1,2,3)] L2 = [33,'b','c',55,22,(1,2,3)] # find out the list with the same elements # L3 = [] # for i in L1: # if i in L2: # L3.append(i) # print(L3) # find ... 阅读全文