Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 1 - 3 of 3 for testFactorial (0.06 seconds)

  1. guava-tests/test/com/google/common/math/BigIntegerMathTest.java

          }
        }
      }
    
      public void testFactorial() {
        BigInteger expected = BigInteger.ONE;
        for (int i = 1; i <= 200; i++) {
          expected = expected.multiply(BigInteger.valueOf(i));
          assertEquals(expected, BigIntegerMath.factorial(i));
        }
      }
    
      public void testFactorial0() {
        assertEquals(BigInteger.ONE, BigIntegerMath.factorial(0));
      }
    
    Created: Fri Dec 26 12:43:10 GMT 2025
    - Last Modified: Wed Nov 19 01:35:24 GMT 2025
    - 27.1K bytes
    - Click Count (0)
  2. android/guava-tests/test/com/google/common/math/DoubleMathTest.java

        for (double d : Arrays.asList(Double.POSITIVE_INFINITY, Double.NEGATIVE_INFINITY, Double.NaN)) {
          assertFalse(DoubleMath.isMathematicalInteger(d));
        }
      }
    
      @GwtIncompatible // Math.ulp
      public void testFactorial() {
        for (int i = 0; i <= DoubleMath.MAX_FACTORIAL; i++) {
          double actual = BigIntegerMath.factorial(i).doubleValue();
          double result = DoubleMath.factorial(i);
    Created: Fri Dec 26 12:43:10 GMT 2025
    - Last Modified: Thu Oct 30 14:15:36 GMT 2025
    - 27.3K bytes
    - Click Count (0)
  3. guava-tests/test/com/google/common/math/DoubleMathTest.java

        for (double d : Arrays.asList(Double.POSITIVE_INFINITY, Double.NEGATIVE_INFINITY, Double.NaN)) {
          assertFalse(DoubleMath.isMathematicalInteger(d));
        }
      }
    
      @GwtIncompatible // Math.ulp
      public void testFactorial() {
        for (int i = 0; i <= DoubleMath.MAX_FACTORIAL; i++) {
          double actual = BigIntegerMath.factorial(i).doubleValue();
          double result = DoubleMath.factorial(i);
    Created: Fri Dec 26 12:43:10 GMT 2025
    - Last Modified: Thu Oct 30 14:15:36 GMT 2025
    - 27.3K bytes
    - Click Count (0)
Back to Top