What is HCF/GCD?
HCF stands for "Highest Common Factor" and GCD stands of "Greatest Common Divisor", both terms are the same. The greatest/highest common devisors number which divides each of the two or more numbers, i.e. HCF/CGD is the highest number which divides each number.
Given two numbers, we have to find GCD/HCF.
Example:
Input:
first = 50
second = 78
Output:
HCF/GCD = 2
Program to find GCD/HCF of two numbers in Kotlin
Output
need an explanation for this answer? contact us directly to get an explanation for this answer