I'd do :
hash = {
foo: 1,
bar: 3,
baz: 3
}
hash.group_by { |_,value| value }.max_by { |key,_| key }.last
# => [[:bar, 3], [:baz, 3]]
Breaking of the above code :
hash.group_by { |_,v| v }
# => {1=>[[:foo, 1]], 3=>[[:bar, 3], [:baz, 3]]}
hash.group_by { |_,v| v }.max_by { |k,_| k }
# => [3, [[:bar, 3], [:baz, 3]]]