OFFSET
1,1
COMMENTS
LINKS
Wikipedia, Composite number
EXAMPLE
Run 1 has length 1; the first composite is 4.
Run 2 has length 3; the first three consecutive composites are 8, 9, and 10.
Run 3 has length 5; the first five consecutive composites are 24, 25, 26, 27, and 28.
4;
8, 9, 10;
24, 25, 26, 27, 28;
90, 91, 92, 93, 94, 95, 96;
114, 115, 116, 117, 118, 119, 120, 121, 122;
114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124;
114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126;
PROG
(Python)
from sympy import isprime
out = []
run = 1
for n in range(4, 10000):
isrun = True
for o in range(run): isrun *= not isprime(n + o - run)
if isrun:
for o in range(run): out.append(n + o - run)
run += 2
print(out)
CROSSREFS
KEYWORD
easy,nonn
AUTHOR
Grant Garcia, Sep 20 2010
STATUS
approved