University of Washington • CSE583 • D. Notkin © 2000
5
Tail recursive
lThe top level call returns a value identical to that of the bottom level call
lWho cares? 
–Performance!
–Scheme requires tail recursion to be implemented as efficiently as iteration
l
l(define member(e l)
l  (cond
l    ((null l) #f)
l    ((equal e (car l)) #t)
l    (else (member e (cdr l)))
l   ))
lOnce an element is a member, it’s always a member
lOnce you start returning true, you keep on returning true until you unwind the whole recursive call stack