Blob


1 (define (append! x y)
2 (set-cdr! (last-pair x) y)
3 x)
5 (define (last-pair x)
6 (if (null? (cdr x))
7 x
8 (last-pair (cdr x))))
10 (define x (list 'a 'b))
11 (define y (list 'c 'd))
12 (define z (append x y))
13 z
14 (a b c d)
15 (cdr x)
16 <response>
17 (define w (append! x y))
18 w
19 (a b c d)
20 (cdr x)
21 <response>
22 p
23 What are the missing <response>s? Draw box-and-pointer diagrams to explain your answer.