ary.to_h is slightly faster than Hash[*a.flatten]