import java.util.*;
import java.io.*;
import java.math.BigInteger;
class test {
public static void main(String [] args)
{
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
try{
BigInteger one = BigInteger.ONE;
ArrayList<BigInteger> arr = new ArrayList<BigInteger>();
String str =br.readLine();
String s= str;
int a = Integer.parseInt(s);
int lin = a;
while(a>0)
{
String str1 = br.readLine();
String s1 = str1;
int num=Integer.parseInt(s1);
for (int p=1; p<=num; p++) {
one = one.multiply(BigInteger.valueOf(p));
}
arr.add(one);
a--;
}
for(int j=0;j<lin;j++)
{
System.out.println(arr.get(j));
}
}
catch(IOException ioe)
{
ioe.printStackTrace();
}
}
}
could not get why i am getting time limit exceede in this code ??? plz hlp