public class Factorial
{

	public static void printFactorial(int number)
	{
		int factorial = 1;
		for (int value=1; value<=number; value++)
		{
			factorial = factorial * value;
		}
		System.out.println(number + "! = " + factorial);
	}

	public static void main(String args[])
	{
		for (int i=1; i<=10; i++)
			printFactorial(i);
	}

}
