#include using namespace std; // problem 808 int main() { unsigned long long n; cin >> n; cout << (n-1)*52+316 << endl; return 0; }