diff --git a/disc/disc07/index.html b/disc/disc07/index.html index 007b64de6..20bcc8714 100644 --- a/disc/disc07/index.html +++ b/disc/disc07/index.html @@ -163,13 +163,11 @@
Now switch to Pensieve:
Once you're on Pensieve, you don't need to return to this page; Pensieve has all the same content (but more features). If for some reason Penseive doesn't work, return to this page and continue with the discussion.
-Post in the #help
channel on Discord if you have trouble.
The draw
function takes a list hand
and a list of unique non-negative
-integers positions
that are all less than the length of hand
. It removes
-hand[p]
for each p
in positions
and returns a list of those elements in
-the order they appeared in hand
(not the order they appeared in positions
).
Fill in each blank with one of these names: list
, map
, filter
, reverse
,
-reversed
, sort
, sorted
, append
, insert
, index
, remove
, pop
,
-zip
, or sum
. See the built-in functions and
-list methods
-documentation for descriptions of what these do.
Discussion Time: Before writing anything, talk as a group about what -process you'll implement in order to make sure the right cards are removed and -returned. Try not to guess-and-check! The purpose of discussion is for you to -try to solve problems without the help of an interpreter checking your work.
- - - - Run in 61A Code -s
and integer i
, s.pop(i)
returns and removes the i
th
-element, which changes the position (index) of all the later elements but
-does not affect the position of prior elements.
-reversed(s)
on a list s
returns an iterator. Calling
-list(reversed(s))
returns a list of the elements in s
in reversed order.
-Aced it? Give yourselves a hand!
- -Overview: A keyboard has a button for every letter of the alphabet. When a @@ -317,14 +253,33 @@