#include using namespace std; int main() { long long p = 52, anc; int n; cin >> n; anc = p * (n - 1) + 316; cout << anc << endl; return 0; }