#include<iostream>
#include<algorithm>
#include<cstring>
#include<cstdio>
#include<cmath>
#include<queue>
#include<vector>
#include <string.h>
#include <math.h>
#include<map>
#include<string.h>
#define ll long long
using namespace std;
ll a,b,c;
ll ans;
int main()
{

    cin>>a>>b>>c;
    ans=b/c-a/c+(bool)(a%c==0);
    cout<<ans<<endl;
    return 0;
}
