Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

get key(s) for min value in dict python

# works with multiple equal minimal values
minval = min(d.values())
res = list(filter(lambda x: d[x]==minval, d))
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #min #dict #python
ADD COMMENT
Topic
Name
5+4 =