v = [gets.to_i, gets.split.map(&:to_i)] AVG = v[1].sum / v[0] v[1].each{|x| puts (50 - (AVG - x) / 2).floor - 1 }