#include #include using namespace std; using lint=int64_t; int main() { int X,Y,L; cin >> X >> Y >> L; int ans=0; if(X!=0)ans++; if(Y<0)ans++; ans+=(abs(X)+L-1)/L; ans+=(abs(Y)+L-1)/L; cout << ans << endl; return 0; }