Printing out a list item by item in a function in section 12/18. whats wrong with the following solutions if anyone please help


#1

n = [3, 5, 7]

for i in range(0, len(n)):
print n[i]
def print_list(x) :
for j in range(0,len(x)) :
print j
print_list(n)


#2

you have a not needed print functions along with the first for loop that i think is messing it up. you can just delete it. dont forget to check spacing also

n = [3, 5, 7]
def print_list(x):
    for i in range(0, len(x)):
        print x[i]
print_list(n)

#3

thank you @ryebread4