14/18


#1

this error is popping up when i put this code i dont understand :persevere::persevere::persevere:
code:
print my_function(range(2))
error:
It looks like you didn’t pass a range consisting of 0, 1, 2 to my_function.
please help me understand!!


#2

Recall that range() returns an iterable consisting of everything from the starting value, to 1 less than the ending value.

range(3)  =>  [0, 1, 2]

The default starting value is 0 so we can leave it off.


#3

yes i figured that part out but i also tried out 3 , but it still gave the same error


#4

Let’s have a look at your code, as well as the lesson itself. Please post a link to the exercise. Thanks.


#5

im sorry i already finished it :yum:


#6

but thanks for explaining anyway


#7

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