I’m new to coding, and I’m not a native english speaker, so maybe it is the problem. So far I had no problem understanding and learning the very basics of python, but it seems I have a really hard time understanding what this exercise want me to do. I think all theses “index” really confuse me !
If someone have the patience to explain to me a little more clearly what I’m suppose to achieve, I would be really glad !
Thanks !
Create a function named double_index that has two parameters named lst and index .
The function should double the value of the element at index of lst and return the new list with the doubled value.
If index is not a valid index, the function should return the original list.
I got confused by the " The function should double the value of the element at index of lst" part of the exercices. Had a hard time to figure out what it meant :
you take the number at that position in the list and double its value.
It wasn’t really clear for me at the time that “index” means that. Kind of obvious now
Spending some time on it with your answer made it clear.