@@ -59,7 +59,7 @@ positive and negative number for the index.
5959### Modifying
6060
6161Lists are * mutable* . This means that once created, you can change their
62- contents and Python will just work with the updated list. You can add to a
62+ contents and Python will just work with the updated list. You can change a
6363list a number of ways:
6464
6565* Setting a value in the list explicitly with ` [n] ` where ` n ` is the index you
@@ -74,9 +74,9 @@ for a more complete reference:
7474 >>> places_to_visit
7575 ['Mexico', 'Portugal', 'Kenya', 'Nepal', 'New Zealand']
7676
77- >>> places_to_visit[5 ] = "Peru"
77+ >>> places_to_visit[1 ] = "Peru"
7878 >>> places_to_visit
79- ['Mexico', 'Portugal ', 'Kenya', 'Nepal', 'New Zealand', 'Peru ']
79+ ['Mexico', 'Peru ', 'Kenya', 'Nepal', 'New Zealand']
8080
8181 >>> places_to_visit.pop()
8282 'Peru'
@@ -89,8 +89,7 @@ for a more complete reference:
8989
9090Try some of these out yourself:
9191
92- * Try adding a country to a list with either the explicit indexing (` [n] ` ) or
93- ` .append() ` . What happens if you give an index that's larger than the list?
92+ * Try adding a country to a list with ` .append() ` .
9493* Take a look at the documentation and try out some of the other methods.
9594 ` .count() ` is a simple one, and ` .reverse() ` is handy to know.
9695
0 commit comments