chickadee » scheme » list-ref

list-ref list kprocedure

Returns the kth element of list. (This is the same as the car of (list-tail list k).) It is an error if list has fewer than k elements.

(list-ref '(a b c d) 2)                ===>  c
(list-ref '(a b c d)
          (inexact->exact (round 1.8))) 
                ===>  c