We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
Testcase 2 has the following input:
8
27 76
16 21
11 10
52 68
80 55
80 71
56 16
39 55
The output is:
1
1
1
3
2
1
4
1
which means for 80 55 the expected number of common factors is 2. 80 = 2^4 * 5 while 55 = 5 * 11, the number of common factors is 1, not 2. Can somebody look into this?
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Common Divisors
You are viewing a single comment's thread. Return to all comments →
Testcase 2 has the following input: 8 27 76 16 21 11 10 52 68 80 55 80 71 56 16 39 55 The output is: 1 1 1 3 2 1 4 1 which means for 80 55 the expected number of common factors is 2. 80 = 2^4 * 5 while 55 = 5 * 11, the number of common factors is 1, not 2. Can somebody look into this?