I am trying to apply a function to every value of a map. fmap
does the job. But what namespace has it moved to?
I also have written the below implementation, but I think this could be better -
(defn map-over
[f m]
(->>
(map (fn [[k v]]
{k (f v)})
m)
(into {})))
The migration page shows that clojure.contrib.generic
has been migrated to algo.generic
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With