I think there is a bug in 14/18, lists and functions.
The instructions are to input a range that will return 0, 1, 2. If you just make a new list that has the values 0, 1, 2 in it, it should return 0, 2, 4 which is does. The problem is is that it says that that is the correct answer and takes me to the next lesson. You don't even have to put in a range for it to accept the answer.
def my_function(x): for i in range(0, len(x)): x[i] = x[i] * 2 return x n = [0, 1, 2] print my_function(n) # Add your range between the parentheses!
the result is:
[0, 2, 4]
and then it tells me to go to the next lesson.
Was there something that I am missing in this lesson or is there a bug?