import std.stdio, std.conv, std.string, std.range, std.math, std.bigint, std.algorithm; void main() { auto N = readln.strip.to!long; (316 + N * 52).writeln; }