Getting the item with the maximun value in list of dicts after grouping the dict by key
<p>I have a list of dicts that looks like this:</p>

<pre><code>[{'apples': 99}, {'bananas': '556685'}, {'apples': 88}, {'apples': '2345566'}]
</code></pre>

<p>I would like to group the items by the key and return the key of the item with the highest value? i.e. sum up the values all the apples and sum up the values of all the bananas ad return the higher one — apple or banana I can't seem to figure out a good way of doing this and I'm trying to avoid using a bunch of loops and counter variables.</p>

<p>(Just out of curiosity, is this possible as a one-liner? if so, how?)</p>

<p>Thanks</p>
