I am a beginner in Clojure.
I have a list of maps:
(def p '({:a 1 :b 2 :c 4}, {:a 2 :b 3 :c 5}, {:a 3 :b 4 :c 6}))
How do I add up all the :b values in the map? Result should be 9
(=2+3+4)
I know I should be using one of the higher level functions like apply,
reduce and combine it with a custom filter function. But not sure how to
write it.
-- Shoeb
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to [email protected]
Note that posts from new members are moderated - please be patient with your
first post.
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en