import java.text.DecimalFormat; import java.util.Scanner; public class No48 { public static void main(String[] args) { Scanner s = new Scanner(System.in); int x = s.nextInt(); int y = s.nextInt(); int l = s.nextInt(); int turn = 0; turn += x != 0 && y < 0 ? 1 : 0; turn += x == 0 && y < 0 ? 2 : 0; turn += x != 0 && y != 0 ? 1 : 0; x = Math.abs(x); y = Math.abs(y); String steps = new DecimalFormat("") .format(Math.ceil((double) x / l) + Math.ceil((double) y / l) + turn); System.out.println(steps); } }