该列表应该得到每个数字的平方.我设法做到了,但我需要删除序列中的最后一个逗号.
当我使用这段代码时:
def multiplicator():
for a in range(3, 20):
b = (a*a)
print(b, end=",")
multiplicator()
Run Code Online (Sandbox Code Playgroud)
我明白了:
9,16,25,36,49,64,81,100,121,144,169,196,225,256,289,324,361,
Run Code Online (Sandbox Code Playgroud)