3.1 Exercise 3.1
Making an accumulator is essentially the same thing as what was done in make-withdraw – we define it to be a function that uses set! to modify the argument passed into the constructor. The code is self-explanatory.
(define (make-accumulator initial) (lambda (more) (begin (set! initial (+ initial more)) initial)))