i try to make a simple list f.e. x=n**2+1
code is
any suggestions?
code is
x=[]
for n in range (4):
y=n**2+1
x.append(y)
print (x)then it prints all...Output:[1]
[1, 2]
[1, 2, 5]
[1, 2, 5, 10]i need only the last...any suggestions?
