Skip to content

Instantly share code, notes, and snippets.

@aoeuidht
Created September 15, 2012 15:52
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save aoeuidht/3728553 to your computer and use it in GitHub Desktop.
Save aoeuidht/3728553 to your computer and use it in GitHub Desktop.
SICP Exercise 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.
(define (sum_squares_top2 c1 c2 c3)
(+
(square max(c1 c2))
(square max((min c1 c2) c3))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment