// compute factorial using a for loop

#include <iostream>

using std::cin;
using std::cout;
using std::endl;

int main()
{
	int n;
	int count, product;

	cout << "Enter n" << endl;
	cin >> n;
	
	for (count=1;count<=n;count++) {
		product *= count;
	}
	
	cout << "The factorial of " << n << " is " << product << endl;

	return( 1 );
}