3 ms·
This is subjective and dependent on the background. I, as a beginner, found the original expression easier to understand, whereas, the "->" macro rewrite seems
by hohenheim 11y ago
This is subjective and dependent on the background. I, as a beginner, found the original expression easier to understand, whereas, the "->" macro rewrite seems puzzling. Specially (map #(+ % 2)) looks as if the values are summed and then % 2 is applies to it.
- jffry 11y agoFor an introduction to absolute beginners it could be something like: (->> (range 10) (map (fn [x] (+ x 2))) (reduce +)) And then later on you can explain the #() shorthand