Skip to content

Instantly share code, notes, and snippets.

;; SICP 1.3
;;
;; Exercise 1.3. Define a procedure that takes three numbers as arguments and
;; returns the sum of the squares of the two larger numbers.
;;
;; This solution is based on discussion (primarily by Jim Weirich) during the
;; Alpha study group's weekly meeting
(define (square x) (* x x))
(define (sum-of-squares x y) (+ (square x) (square y)))