#include<iostream>
using namespace std;
int main()
{

int y,a;
cin >> y;
a=y-1971;
cout << a;


    return 0;
}

