Clojure: summing values in a collection of maps
问题 I am trying to sum up values of a collection of maps by their common keys. I have this snippet: (def data [{:a 1 :b 2 :c 3} {:a 1 :b 2 :c 3}] (for [xs data] (map xs [:a :b])) ((1 2) (1 2)) Final result should be ==> (2 4) Basically, I have a list of maps. Then I perform a list of comprehension to take only the keys I need. My question now is how can I now sum up those values? I tried to use "reduce" but it works only over sequences, not over collections. Thanks. ===EDIT==== Using the