6,10,14,15,21,22,....ad inf
This sequence consists of products of two distinct primes.
1. What is the 1st appearance of 3 successive numbers?
2. How many triplets like n, n+1, n+2 are there below 2000?
3. Prove that 4 numbers in a succession cannot appear in this sequence.
33 34 35 3 ... the first
85 86 87 3
93 94 95 3
141 142 143 3
201 202 203 3
213 214 215 3
217 218 219 3
301 302 303 3
393 394 395 3
445 446 447 3
633 634 635 3
697 698 699 3
921 922 923 3
1041 1042 1043 3
1137 1138 1139 3
1261 1262 1263 3
1345 1346 1347 3
1401 1402 1403 3
1641 1642 1643 3
1761 1762 1763 3
1837 1838 1839 3
1893 1894 1895 3
1941 1942 1943 3
1981 1982 1983 3,
a total of 24 occurrences below 2000, from:
4 kill "nsqsmprm.txt"
5 open "nsqsmprm.txt" for output as #2
10 for N=6 to 2000
20 Pd=prmdiv(N)
30 Q=N//Pd
40 if prmdiv(Q)=Q and Q<>Pd and Q>1 then InRow=InRow+1:else InRow=0
50 if InRow>2 then print N,InRow:print #2,N-2,N-1,N,InRow:inc Ct
60 next
65 print Ct:print #2,Ct
70 close #2
999 end
|
Posted by Charlie
on 2020-08-24 20:07:33 |