I have this
my_dict = {'x':500, 'y':500, 'z': 500}
min_s=min(my_dict, key=my_dict.get)
when I print the min_s
, it arbitrary print either x
or y
or z
, but I want to just print the first key meaning x
. How can I do this?
Also, how can I check if all values are the same ?
Thanks