0
Find Lcm of two numbers using java
take two numbers has input
3 Respostas
0
If you know how to find GCD of two numbers a, b, LCM can be found by (a*b)/GCD(a,b)
0
I want without gcd
0
Take maximum of the two numbers and continue producing the multiples of this number until it is also the multiple of smaller number.
Or there is another tedious method of finding prime factors of both numbers and union them. product of all union numbers gives you LCM.