import java.util.Scanner;
import java.math.BigInteger;
class Main
{
// standard Java class name in UVa OJ
public static void main(String[] args)
{
int n;
Scanner sc= new Scanner(system.in);
n=sc.nextInt;
BigInteger fac = BigInteger.ONE;
for (int i = 2; i <=n; i++)
fac = fac.multiply(BigInteger.valueOf(i));
// it is in the library!
System.out.println(fac);
}
}
import java.math.BigInteger;
class Main
{
// standard Java class name in UVa OJ
public static void main(String[] args)
{
int n;
Scanner sc= new Scanner(system.in);
n=sc.nextInt;
BigInteger fac = BigInteger.ONE;
for (int i = 2; i <=n; i++)
fac = fac.multiply(BigInteger.valueOf(i));
// it is in the library!
System.out.println(fac);
}
}
No comments:
Post a Comment