Tips to get AC
Boyiddha_ asked 7 months ago
Efficient approach 1 : just apply Euclid algo. to find gcd of two numbers ... and also apply property of gcd as GCD(a,b,c......) = GCD(a,GCD(b,c)....) and in euclid algo to find mathmatical % operation use BIG Integer ( since number are very large )
Efficent approach 2 : just think , try & think & think .... it is possible to find gcd of range A to B in O(1).
Note : I got AC in both approach.
This topic has not been answered yet. Be the first!