/**
 * This function finds the greatest common divisor (GCD) of two integers.
 *
 * @param a an integer
 * @param b an integer
 * @return The GCD of 'a' and 'b'
 */
fun gcd(a: Int, b: Int): Int {

    var numA = a
    var numB = b

    while (numB != 0) {
        val temp = numA
        numA = numB
        numB = temp % numB
    }

    return numA
}
/**
 * This function finds the greatest common divisor (GCD) of two integers.
 *
 * @param a an integer
 * @param b an integer
 * @return The GCD of 'a' and 'b'
 */
fun gcd(a: Int, b: Int): Int {
/**
 * This function finds the greatest common divisor (GCD) of two integers.
 *
 * @param a an integer
 * @param b an integer
 * @return The GCD of 'a' and 'b'
 */
fun gcd(a: Int, b: Int): Int {

    var numA = a
    var numB = b

    while (numB != 0) {
        val temp = numA
        numA = numB
        numB = temp % numB
    }

    return numA
}