Skip to content

Instantly share code, notes, and snippets.

@Olychuck
Olychuck / Factorialcounter.java
Created February 11, 2012 02:10
Embedly Questions
import java.math.BigInteger;
public class Factorialcounter {
/**
* Simply goes through each factorial and tests the cumulative number
*/
public static int numb(int s) {
BigInteger a = new BigInteger(String.valueOf(s));
while (--s > 0) {
a = a.multiply(new BigInteger(String.valueOf(s)));