3 ms·
I had similar thoughts when I was first learning a lisp. Unlike the author, I was enamored with the lack of syntax and the expressive power that was there. Sure
by ihodes 15y ago
I had similar thoughts when I was first learning a lisp. Unlike the author, I was enamored with the lack of syntax and the expressive power that was there. Sure, it's a Turing-complete language like any other, but for me it was a pleasure to hack with. Not only that, but you can actually do things with it (manipulate the language itself, from within the language itself…whoa) that I would only later realize the power of. Turns out you rarely need to use that power.
For instance, I'd do (untested):
(defn prime? [x] (every? (fn [n] (not (zero? (mod x n))))
(range 2 (Math/sqrt x))))
(doseq (map pr (filter prime? (range 0 20))))
for the same effect. And I really was happy to write that. It makes sense.
NB: I'd never put such code into production, and I think it should be a warning sign that a purported problem in a language/dialect be based around minimal experience regarding an example.