num = int(input()) ans = 316 + num * 52 print(ans)