Skip to content

Commit 44358e8

Browse files
authored
Merge pull request #1002 from indiauppal/edit_lists
Edit lists
2 parents 2bd4f3d + 76ae54c commit 44358e8

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

_episodes/04-lists.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,7 @@ copy it and then modify this list, we can cause all sorts of trouble. This also
273273
the list using the above functions:
274274
275275
~~~
276-
odds = [1, 3, 5, 7]
276+
odds = [3, 5, 7]
277277
primes = odds
278278
primes.append(2)
279279
print('primes:', primes)
@@ -282,8 +282,8 @@ print('odds:', odds)
282282
{: .language-python}
283283
284284
~~~
285-
primes: [1, 3, 5, 7, 2]
286-
odds: [1, 3, 5, 7, 2]
285+
primes: [3, 5, 7, 2]
286+
odds: [3, 5, 7, 2]
287287
~~~
288288
{: .output}
289289
@@ -292,7 +292,7 @@ same list. If all we want to do is copy a (simple) list, we can again use the `l
292292
do not modify a list we did not mean to:
293293
294294
~~~
295-
odds = [1, 3, 5, 7]
295+
odds = [3, 5, 7]
296296
primes = list(odds)
297297
primes.append(2)
298298
print('primes:', primes)
@@ -301,8 +301,8 @@ print('odds:', odds)
301301
{: .language-python}
302302
303303
~~~
304-
primes: [1, 3, 5, 7, 2]
305-
odds: [1, 3, 5, 7]
304+
primes: [3, 5, 7, 2]
305+
odds: [3, 5, 7]
306306
~~~
307307
{: .output}
308308

0 commit comments

Comments
 (0)