Clojure Fibonacci series
(defn fibo [x]
(if (> x 1) (+ (fibo (- x 1)) (fibo (- x 2))) x) )
(println (map fibo (range 20)))
Clojure is a functional language that targets, amongst others, the Java Virtual Machine. You can try Clojure with an online interpreter.
<< Home