Your list is not in order.
You will get 6,10,14,22,26,..............,15,21,33,39,......... ...........35,55,65.......etc
HI, i am trying to find the first 2000,000 square free semi-prime numbers( mathWorld , oeis). I have generated the prime numbers but to get these semi-prime numbers i am trying as follows:
however on chaging either limit1 or limit2 gives different values for semiprime[200000] . So what should be correct values of these variables?Code:int limit1 = 1000; int limit2 = 2000; for(i=0;i<=limit1;i++) { for(j=i+1;j<=limit2;j++) { semiPrimes[size++]=(primes[i]*primes[j]); } limit2++; }
Thanks.