/*        All is Well        */
#include <bits/stdc++.h>
using namespace std;
#define tera_baap_aaya main
#define TEZZ ios_base::sync_with_stdio(false);cin.tie(0);cout.tie(0);//
#define ll long long int
#define PB push_back
const ll C=998244353;
////////////////////
bool checkprime(ll n)
{
    for (int i=2;i*i<=n;i++)
    {
        if (n%i==0)
        {
            return false;
        }
    }
    return true;
}//////////
ll ncr(int n, int r)
{
    if (r>n)
    {
        return 0;
    }
    r=min(r,n-r);
    ll num=1,den=1;
    for (int i=0;i<r;i++)
    {
        num*=n-i;
        den*=i+1;
        ll g=__gcd(num,den);
        num/=g;
        den/=g;
    }
    return num;
}//////////
ll pasc_triangle(int n, int r)
{
    if (r>n)
    {
        return 0;
    }
    r=min(r,n-r);
    if (r==0)
    {
        return 1;
    }
    vector <ll> a;
    a.PB(1);
    for (int i=0;i<n-1;i++)
    {
        vector <ll> b;
        b.PB(1);
        for (int j=1;j<a.size();j++)
        {
            b.PB((a[j]+a[j-1])%C);
        }
        b.PB(1);
        a=b;
    }
    return (a[r]+a[r-1])%C;
}//////////
vector <ll> fact(200000+1);
void factarray()
{
    fact[0]=1%C;
    for (int i=1;i<200000+1;i++)
    {
        fact[i]=(fact[i-1]*i)%C;
    }
}//////////
ll modpower(ll n,ll p)
{
    if (p==0)
    {
        return 1%C;
    }
    ll m=modpower(n,p/2);
    m*=m;
    m%=C;
    if (p%2)
    {
        m*=n%C;
        m%=C;
    }
    return m;
}//////////
ll modinverse(ll n)
{
    return modpower(n, C-2);
}//////////
ll ncrmodc(int n,int r)
{
    if (r>n)
    {
        return 0;
    }
    r=min(r,n-r);
    return ((fact[n]*modinverse(fact[r]))%C*modinverse(fact[n-r]))%C;
}//////////
/******************/
void solve()
{
    int a,b,c,d;
    cin>>a>>b>>c>>d;
    cout<<b-c;
}//////////
////////////////////
int tera_baap_aaya()
{
    TEZZ;
    int t=1;
    //cin>>t;
    //factarray();
    while (t--)
    {
        solve();
        cout<<"\n";
    }
    return 0;
}
/*..fir milenge chalte chalte*/

#include<bits/stdc++.h>
using namespace std;
#define flash ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);

int main()
{
    flash
    int t = 1;
    //cin>>t;
    while (t--) {
        int a,b,c,d;
        cin>>a>>b>>c>>d;
        cout<<b-c;
    }
    return 0;
}