#include <bits/stdc++.h>
using namespace std;
template <typename T> void read(T &t) {
	t=0; char ch=getchar(); int f=1;
	while (ch<'0'||ch>'9') { if (ch=='-') f=-1; ch=getchar(); }
	do { (t*=10)+=ch-'0'; ch=getchar(); } while ('0'<=ch&&ch<='9'); t*=f;
}
int n,tot;
vector<int> g[1010];
void add(int x,int y) {
	x++,y++;
	g[x].push_back(y);
}
int mx,dis[1010];
queue<int> q;
int main() {
	//freopen("1.txt","r",stdin);
	read(n);
	srand(time(0));
	for (int i=0;i<n;i++) printf("%d %d\n",(i*2)%n+1,(i*2+1)%n+1);
	/*for (int i=1;i<=n;i++) {
		memset(dis,-1,sizeof(dis));
		q.push(i);
		dis[i]=0;
		while (!q.empty()) {
			int u=q.front(); q.pop();
			for (int j=0,v;j<g[u].size();j++) {
				v=g[u][j];
				if (dis[v]==-1) dis[v]=dis[u]+1,q.push(v);
			}
		}
		for (int j=1;j<=n;j++) {
			if (dis[j]==-1) { printf("-1\n"); return 0; }
			mx=max(mx,dis[j]);
		}
	}
	printf("%d\n",mx);*/
	return 0;
}
/*
  0. Enough array size? Enough array size? Enough array size? Interger overflow?
  
  1. Think TWICE, Code ONCE!
  Are there any counterexamples to your algo?
    
  2. Be careful about the BOUNDARIES!
  N=1? P=1? Something about 0?
    
  3. Do not make STUPID MISTAKES!
  Time complexity? Memory usage? Precision error?
*/
#include <bits/stdc++.h>
#define int long long
#define menhera_chan_is_mine ios::sync_with_stdio(false);cin.tie(0);cout.tie(0);
#define pb push_back
#define pi pair<int, int>
#define BE(i) i.begin(),i.end()
#define fi first
#define se second
#define INF 2147483646
#define mkp make_pair
#define ist insert
#define mod 100003
//#pragma GCC optimize("Ofast,unroll-loops,no-stack-protector,fast-math")
//#pragma GCC optimize("O2")
using namespace std;
int min(int a, int b){return a < b ? a : b;}
int max(int a, int b){return a > b ? a : b;}
bool isprime(int k){bool is=1 ; for ( int i = 2 ; i*i <= k ; i++ ) if ( k % i == 0 ) is = 0 ; return k>1?is:0;}
const double PI=acos(-1);

int d,a,b,c;
void sol(){
	cin >>a>>b>>c>>d;
	cout <<b-c;
}
signed main(){
    menhera_chan_is_mine
    int T=1;
    //cin >>T;
    while (T--)
        sol();

    return 0;
}
