Android Utililty Methods Int GCD

List of utility methods to do Int GCD

Description

The list of methods to do Int GCD are organized into topic(s).

Method

intgcd(int p, int q)
Computes the greatest common divisor of the absolute value of two numbers, using a modified version of the "binary gcd" method.
intgcdPositive(int a, int b)
Computes the greatest common divisor of two positive numbers (this precondition is not checked and the result is undefined if not fulfilled) using the "binary gcd" method which avoids division and modulo operations.