#include<cstdio>
#include<cstring>
#include<algorithm>
using namespace std;

int main() {
	int n,sum=0;
	bool a[1000000005] = { false };
	scanf("%d", &n);
	getchar();
	for (int i = 0; i < n; i++) {
		a[i] = !a[i];
		if (a[i] == true) sum++;
		else if (a[i] == false) sum--;
	}
	printf("%d", sum);

}