Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 1 of 1 for getLowestSetBit (0.07 sec)

  1. guava/src/com/google/common/math/BigIntegerMath.java

      }
    
      /** Returns {@code true} if {@code x} represents a power of two. */
      public static boolean isPowerOfTwo(BigInteger x) {
        checkNotNull(x);
        return x.signum() > 0 && x.getLowestSetBit() == x.bitLength() - 1;
      }
    
      /**
       * Returns the base-2 logarithm of {@code x}, rounded according to the specified rounding mode.
       *
       * @throws IllegalArgumentException if {@code x <= 0}
    Registered: Fri Nov 01 12:43:10 UTC 2024
    - Last Modified: Wed Oct 16 17:21:56 UTC 2024
    - 18.8K bytes
    - Viewed (0)
Back to top