Discussion about this post

User's avatar
Ed Silva's avatar

data = [1, 2, 3, 4]

def square_list(lst):

y = []

for x in (range(len(lst))):

y.append(lst[x] ** 2)

return(y)

n = square_list(data)

print(n)

Expand full comment
5 more comments...

No posts

Ready for more?