Thursday 3 January 2008

Find g.c.d of two number using c program



Definition
of HCF (Highest
common factor):



HFC is also called greatest
common divisor (gcd).
HCF of two numbers is a largest positive numbers which can divide both numbers
without any remainder.  For example HCF
of two numbers 4 and 8 is 2 since 2 is the largest positive number which can
dived 4 as well as 8 without a remainder. 



Logic
of HCF or GCD of any two numbers:



In HCF we try

No comments:

Post a Comment