you have been given number n and p, you need to find n! % p (n factorial mod p). p is a prime no.
1<= n <= 10^9 1<= p <= 10^9 1<= abs(n - p) <= 1000
The first line contains the integer n and p.
Output an integer in a line containing n! modulo P.