- Sort Score
- Num 10 results
- Language All
Results 1 - 3 of 3 for floorPowerOfTwo (0.07 seconds)
-
android/guava/src/com/google/common/math/IntMath.java
* checkedPow(2, log2(x, FLOOR))}. * * @throws IllegalArgumentException if {@code x <= 0} * @since 20.0 */ public static int floorPowerOfTwo(int x) { checkPositive("x", x); return Integer.highestOneBit(x); } /** * Returns {@code true} if {@code x} represents a power of two. *
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Thu Jan 29 22:14:05 GMT 2026 - 26.1K bytes - Click Count (0) -
guava-tests/test/com/google/common/math/BigIntegerMathTest.java
} } public void testCeilingPowerOfTwoZero() { assertThrows( IllegalArgumentException.class, () -> BigIntegerMath.ceilingPowerOfTwo(BigInteger.ZERO)); } public void testFloorPowerOfTwoZero() { assertThrows( IllegalArgumentException.class, () -> BigIntegerMath.floorPowerOfTwo(BigInteger.ZERO)); }
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Tue Mar 03 04:51:56 GMT 2026 - 27.1K bytes - Click Count (0) -
android/guava/src/com/google/common/math/LongMath.java
* checkedPow(2, log2(x, FLOOR))}. * * @throws IllegalArgumentException if {@code x <= 0} * @since 20.0 */ public static long floorPowerOfTwo(long x) { checkPositive("x", x); // Long.highestOneBit was buggy on GWT. We've fixed it, but I'm not certain when the fix will // be released.
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Mon Mar 09 23:01:02 GMT 2026 - 46.8K bytes - Click Count (0)