Lists And Functions 9/18 – Using an Element From a List in a Function


#1



https://www.codecademy.com/courses/python-beginner-nzzVa/2/2?curriculum_id=4f89dab3d788890003000096


i dot know because everytime i click save and submit it changes


python to actually help me


def list_function(x):
     x[1] += 3
     return x

n = [3, 5, 7]
print list_function(n)


#2

All you need to do in this scenario is return the first index of x, so x[1] += 3 is not a solution. Look at the example given to the left and adjust the return line to match the requirement.


#3

that didn't work.
every time i click save and submit, it changes


#4

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.