ApasScript.

Big Numbers

bigGcd

The greatest common divisor of a and b, computed via arbitrary-precision integers -- stays exact for magnitudes far beyond ordinary 128-bit arithmetic.

bigPow

base raised to a non-negative integer exponent, computed via arbitrary-precision integers -- stays an exact integer at any magnitude, unlike ordinary exponentiation which falls back to an approximate float once it outgrows native range.

floor

The largest whole number <= x, exact at any size.

ceil

The smallest whole number >= x, exact at any size.

round

x rounded to the nearest whole number (halves away from zero), exact at any size.

trunc

x with its fractional part dropped (towards zero).

frac

The fractional part x - trunc(x).

numerator

The numerator of x in lowest terms.

denominator

The denominator of x in lowest terms.

isInteger

True if x is a whole number.

mixedFraction

x as a mixed number, e.g. 7/2 is "3 1/2" and -7/2 is "-3 1/2".