0
Why insert doesn't work as append?
I know it's crazy. But with my curiosity I want to know why it doesn't add 'is' to last index in the list https://code.sololearn.com/c1V5nZpjskeK/?ref=app
2 odpowiedzi
+ 3
If you look a the documentation (https://docs.python.org/3/tutorial/datastructures.html#more-on-lists) you can read: “... Insert an item at a given position. The first argument is the index of the element before which to insert ...”
+ 1
Bawantha Nawela. Try
words.insert(len(words), "is")