a = gets.split.map &:to_i b = gets.split.map &:to_i c = (b[0] - a[0]).abs + (b[1] - a[1]).abs c = c.to_f c /= 2 p c