- Sort Score
- Result 10 results
- Languages All
Results 1 - 6 of 6 for saturatedPow (0.19 sec)
-
android/guava-tests/test/com/google/common/math/IntMathTest.java
public void testSaturatedPow() { for (int a : ALL_INTEGER_CANDIDATES) { for (int b : EXPONENTS) { assertOperationEquals( a, b, "s^", saturatedCast(valueOf(a).pow(b)), IntMath.saturatedPow(a, b)); } } } private static final BigInteger MAX_INT = BigInteger.valueOf(Integer.MAX_VALUE); private static final BigInteger MIN_INT = BigInteger.valueOf(Integer.MIN_VALUE);
Java - Registered: Fri May 03 12:43:13 GMT 2024 - Last Modified: Wed Feb 07 17:50:39 GMT 2024 - 24.5K bytes - Viewed (0) -
guava-tests/test/com/google/common/math/IntMathTest.java
public void testSaturatedPow() { for (int a : ALL_INTEGER_CANDIDATES) { for (int b : EXPONENTS) { assertOperationEquals( a, b, "s^", saturatedCast(valueOf(a).pow(b)), IntMath.saturatedPow(a, b)); } } } private static final BigInteger MAX_INT = BigInteger.valueOf(Integer.MAX_VALUE); private static final BigInteger MIN_INT = BigInteger.valueOf(Integer.MIN_VALUE);
Java - Registered: Fri Apr 12 12:43:09 GMT 2024 - Last Modified: Wed Feb 07 17:50:39 GMT 2024 - 24.5K bytes - Viewed (0) -
android/guava/src/com/google/common/math/IntMath.java
* case {@code Integer.MAX_VALUE} or {@code Integer.MIN_VALUE} is returned, respectively. * * @since 20.0 */ public static int saturatedPow(int b, int k) { checkNonNegative("exponent", k); switch (b) { case 0: return (k == 0) ? 1 : 0; case 1: return 1; case (-1):
Java - Registered: Fri Apr 26 12:43:10 GMT 2024 - Last Modified: Wed Feb 07 17:50:39 GMT 2024 - 23.5K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/math/LongMathTest.java
public void testSaturatedPow() { for (long a : ALL_LONG_CANDIDATES) { for (int b : EXPONENTS) { assertOperationEquals( a, b, "s^", saturatedCast(valueOf(a).pow(b)), LongMath.saturatedPow(a, b)); } } } private void assertOperationEquals(long a, long b, String op, long expected, long actual) { if (expected != actual) {
Java - Registered: Fri May 03 12:43:13 GMT 2024 - Last Modified: Mon Mar 04 20:15:57 GMT 2024 - 32.5K bytes - Viewed (0) -
guava-tests/test/com/google/common/math/LongMathTest.java
public void testSaturatedPow() { for (long a : ALL_LONG_CANDIDATES) { for (int b : EXPONENTS) { assertOperationEquals( a, b, "s^", saturatedCast(valueOf(a).pow(b)), LongMath.saturatedPow(a, b)); } } } private void assertOperationEquals(long a, long b, String op, long expected, long actual) { if (expected != actual) {
Java - Registered: Fri Apr 12 12:43:09 GMT 2024 - Last Modified: Mon Mar 04 20:15:57 GMT 2024 - 32.5K bytes - Viewed (0) -
android/guava/src/com/google/common/math/LongMath.java
* case {@code Long.MAX_VALUE} or {@code Long.MIN_VALUE} is returned, respectively. * * @since 20.0 */ @SuppressWarnings("ShortCircuitBoolean") public static long saturatedPow(long b, int k) { checkNonNegative("exponent", k); if (b >= -2 & b <= 2) { switch ((int) b) { case 0: return (k == 0) ? 1 : 0; case 1: return 1;
Java - Registered: Fri Apr 26 12:43:10 GMT 2024 - Last Modified: Wed Feb 07 17:50:39 GMT 2024 - 44.6K bytes - Viewed (0)