#include #include #include int main(){ int x, y, l, lx, ly, rotFlag; scanf("%d %d %d", &x, &y, &l); lx = (int)ceil( (double)abs(x)/l ); ly = (int)ceil( (double)abs(y)/l ); if(y < 0) rotFlag = 2; else if(x == 0) rotFlag = 0; else rotFlag = 1; printf("%d\n", lx + ly + rotFlag); return 0; }