In the name "greatest common divisor", the adjective "greatest" may be replaced by ”highest”, and the word" divisor" may be replaced by" factor", so that other names include greatest common factor (gcf), etc. This impression can be extended to polynomials (see polynomial greatest common divisor) and other commutative rings. Greatest common divisors can in principle be computed by determining the prime factorizations of the two numbers and comparing factors

COMING SOON!

```
package Mathematics
object GreaterCommonDivisor {
/**
* Method returns the Greatest Common Divisor of two numbers n, m
*
* @param num1, num2
* @return
*/
def gcd(num1: Long, num2: Long): Long = {
if (num2 == 0) num1
else gcd(num2, num1 % num2)
}
}
```