compareProducts

fun compareProducts(a: Long, b: Long, c: Long, d: Long): Int

The sign of a·b − c·d: negative, zero or positive as a·b is below, equal to or above c·d. Exact for every input, so comparing two fractions a/c and d/b with positive denominators by cross-multiplying can no longer throw or wrap.