class A def initialize x, y = gets.chomp.split(' ').map(&:to_i) puts (2 * Math.sqrt(x**2+y**2) + 1).floor end end A.new