I have two lists of dotted-pairs of the form:
(((key1 . value1) . 5)
((key2 . value2) . 7))
(((key2 . value2) . 3)
((key3 . value3) . 9))
i want the result to be an association list:
(((key1 . value1) . 5)
((key2 . value2) . 10)
((key3 . value3) . 9))
How do i add two association lists by values in emacs lisp? In other words, if two alists have the same key, then values for that key should be added together in resulting alist.
The most probable answer for this is some elisp snippet, but i would also prefer a nifty emacs macro.