Sydney chooses two different primes, both greater than 10 and computes their product P. The product P is less than 500. How many different possible values of P are there?
Using a little bit of case work, we find that P can have 19 different values.
a=(11 , 13 , 17 , 19 , 23 , 29 , 31 , 37 , 41 , 43); i=0; j=2; c=a[0]*a[1]; cycle: m=a[i]*a[j]; if(m<500, c=sort(c,m), goto next);j++; if(j next: i++; j=i+1; if(j
OUTPUT: (143, 187, 209, 221, 247, 253, 299, 319, 323, 341, 377, 391, 403, 407, 437, 451, 473, 481, 493)>>Total = 19 such numbers.