[archives] [homepage]

Problem 2.25
Friday, August 23, 2019; ago; Download .md

SICP Exercise 2.25

This exercise is mostly hit and trial.

A.

(define items (list 1 2 (list 5 7) 9))

> (car (cdr (cdr (cdr items))))
9
> (car (cdr (cdr items)))
(5 7)
> (car (cdr (car (cdr (cdr items)))))
7

B.

(define items2 (list (list 7))) 

> (car (car items2))
7

C.

> (car (cdr (car (cdr (car (cdr (car (cdr (car (cdr (car (cdr items3))))))))))))
7