Hello,
Im now at the last exercise of the beginners exercise of 4clojure.
I figured out that this solution works.
(fn [default lijst1]
(loop [lijst lijst1 d {}]
(if (empty? lijst)
d
(recur (rest lijst) (assoc d (first lijst) default)
But as I see it lijst lijst 1 and
Hi Roelof,
On May 3, 2014, at 3:09 AM, Roelof Wobben rwob...@hotmail.com wrote:
Hello,
Im now at the last exercise of the beginners exercise of 4clojure.
nice!
I figured out that this solution works.
(fn [default lijst1]
(loop [lijst lijst1 d {}]
(if (empty? lijst)
(fn [default initial-keys]
(loop [remaining-keys initial-keys
result-map {}]
(if (empty? remaining-keys)
result-map
(let [key (first remaining-keys)
remaining-keys' (rest remaining-keys)
result-map' (assoc
On May 3, 2014, at 6:42 AM, Roelof Wobben rwob...@hotmail.com wrote:
(fn [default initial-keys]
(loop [remaining-keys initial-keys
result-map {}]
(if (empty? remaining-keys)
result-map
(let [key (first remaining-keys)