From 751dff6ba0af4cea6b0f172919005ae56f350c39 Mon Sep 17 00:00:00 2001 From: Ramakrishnan Muthukrishnan Date: Fri, 23 Apr 2010 00:23:59 +0530 Subject: [PATCH] reorganisation of directories --- pom.xml | 2 +- src/{main/clojure => }/sicp/ch1_1.clj | 0 src/{main/clojure => }/sicp/ch1_2.clj | 5 +++++ 3 files changed, 6 insertions(+), 1 deletion(-) rename src/{main/clojure => }/sicp/ch1_1.clj (100%) rename src/{main/clojure => }/sicp/ch1_2.clj (99%) diff --git a/pom.xml b/pom.xml index 62b756b..2f380fb 100644 --- a/pom.xml +++ b/pom.xml @@ -26,7 +26,7 @@ - src/main/clojure + src diff --git a/src/main/clojure/sicp/ch1_1.clj b/src/sicp/ch1_1.clj similarity index 100% rename from src/main/clojure/sicp/ch1_1.clj rename to src/sicp/ch1_1.clj diff --git a/src/main/clojure/sicp/ch1_2.clj b/src/sicp/ch1_2.clj similarity index 99% rename from src/main/clojure/sicp/ch1_2.clj rename to src/sicp/ch1_2.clj index 18c14bd..cd210be 100644 --- a/src/main/clojure/sicp/ch1_2.clj +++ b/src/sicp/ch1_2.clj @@ -557,3 +557,8 @@ See the pdfs in the directory for the answers. (defn ffib [n] (ffib-iter 1 0 0 1 n)) +;;; Section 1.2.5: GCD +(defn mygcd [a b] + (if (= b 0) + a + (mygcd b (rem a b)))) \ No newline at end of file -- 2.37.2