a, b, c = gets.split.map &:to_i puts [a - b, b - c, c - a].map(&:abs).min