After the do loop the variable x is sent to car L intially and then is updated to first element of everything but first element in list.
Code: Select all
(Toggle Plain Text)
(define (sumiteration L)
(do ((x (car L) (car(cdr L))))
((null? L))
(set! sum (+ sum x)))
)