using System; using System.Linq; public class yukicoder{ public static double walk(double goal, double n) { double x = Math.Abs(goal); return Math.Ceiling(x / n); } public static double turn(double NS, double EW) { double command = 0; if(NS < 0) { command = command + 2; } if(EW != 0) { command++; } return command; } public static void Main(){ double EW = double.Parse(Console.ReadLine()); double NS = double.Parse(Console.ReadLine()); double forward = double.Parse(Console.ReadLine()); Console.WriteLine(turn(NS, EW) + walk(NS, forward) + walk(EW, forward)); } }