Discuss / Python / fs.append(f())就是1,4,9了

fs.append(f())就是1,4,9了

Topic source

分享公元

#1 Created at ... [Delete] [Delete and Lock User]

def count(): fs = [] for i in range(1, 4): def f(): return i*i fs.append(f()) return fs

f1, f2, f3 = count()

这样就是1,4,9了


  • 1

Reply