import java.util.Scanner; // program uses class Scanner

public class BPIH4E7
{
     // main method begins execution of Java application
     public static void main( String args[] )
     {            
        // create Scanner to obtain input from command window
        Scanner input = new Scanner( System.in );         
	    int number; // number to get   
        int y=0;
        System.out.print( "Enter the number n=" ); // prompt                     
        number=input.nextInt(); // read first number from user
        long factorial=1;
        String s="";
        int i=1;
        while(i<=number)
        {  factorial*=i; 
           i++;
        }
        s=""+number+"! = "+factorial;
        System.out.println(s);
     } // end method main
} // end class BPIH4E1
