program Factorial;
var
n: integer;
result: longint;
begin
result := 1;
Readln(n);
repeat
result := result * n;
n := n - 1;
until
n = 0;
Writeln(result);
end.
program Factorial;
var
n: integer;
result: longint;
begin
result := 1;
Readln(n);
repeat
result := result * n;
n := n - 1;
until
n = 0;
Writeln(result);
end.