python 2.7 counting number of dictionary items with given value,sum(d.values())