From a92e91895009da9c9b61c34ef931340f50eb9fc4 Mon Sep 17 00:00:00 2001 From: Marco Date: Tue, 20 Aug 2024 16:44:37 +0200 Subject: [PATCH] sicp exercise 1.3 --- exercise1-3.scm | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 exercise1-3.scm diff --git a/exercise1-3.scm b/exercise1-3.scm new file mode 100644 index 0000000..769dc87 --- /dev/null +++ b/exercise1-3.scm @@ -0,0 +1,13 @@ +(define (square-sum-larger-two a b c) + (if (< a b) + (if (< a c) + (+ (* c c) (* b b)) + (+ (* a a) (* b b))) + (if (> c b) + (+ (* c c) (* a a)) + (+ (* b b) (* a a))) + ) +) + + +(print (square-sum-larger-two 4 3 2))