1246 - Find Terrorists
Solution Description : Math prime number and divisor problem In this problem the max limit of L & H is 10000 for n= 2 to 10000 --- if number of divisor is a prime then set ans[i]=true Here you got max number of divisor = 64, so you need to generate prime number up to 64 for check prime number. Now input L & H for i=L to H ---if ans[i]==true then print i |
||||||||||