var i,n:integer;
s:real;
begin
write('Nhap n = ');readln(n);
s:=1;
if n mod 2 = 0 then
begin
for i:=2 to n do
begin
s:=s*i;
i:=i+2;
end;
end
else
begin
for i:=1 to n do
begin
s:=s*i;
i:=i+2;
end;
write('Tong la ',s:10:2);
readln;
end.
#include <bits/stdc++.h>
using namespace std;
long long n,i,s;
int main()
{
cin>>n;
if (n%2==0)
{
s=1;
for (i=1; i<=n; i++)
if (i%2==0) s=s*i;
cout<<s;
}
else
{
s=1;
for (i=1; i<=n; i++)
if (i%2==1) s=s*i;
cout<<s;
}
return 0;
}