12345678910111213141516171819 |
-
-
-
- import java.math.BigInteger;
-
- public class Factorial {
-
- public BigInteger factorialOf(Integer value){
- BigInteger answer = BigInteger.valueOf(1);
- for (long i = 2 ; i<= value.longValue(); i++){
-
- answer = answer.multiply(BigInteger.valueOf(i));
- }
-
- return answer;
- }
-
- }
|