#include<iostream>
using namespace std;
//recurcive way to find factorial of number
//int factorial(int n)
//{
// if(n==0)
// {
// return 1;
// }
// int fact=1;
// fact=n*factorial(n-1);
// return fact;
//}
//int main()
//{
// cout<<factorial(5)<<endl;
//}
//itrative way to find factorial
int main()
{
int i, n,fact;
fact=1;
cout<<"Enter number "<<endl;
cin>>n;
for(i=n;i>0;i--)
{
fact=fact*i;
}
cout<<fact;
}