Exercise 3.3.3: (back)
;; constant (define PI 3.142) ;; square : number -> number (define (square x) (* x x)) ;; area-circle : number -> number (define (area-circle radius) (* PI (square radius))) ;; circumference-circle : number -> number (define (circumference-circle radius) (* 2 PI radius)) ;; area-cylinder : number number -> number ;; 2(pi r^2) + (2 pi r)h (define (area-cylinder radius height) (+ (* 2 (area-circle radius)) (* (circumference-circle radius) height)))