RosettaCodeData/Task/Yellowstone-sequence/11l/yellowstone-sequence-2.11l
2023-07-01 13:44:08 -04:00

13 lines
233 B
Text

F yellow(n)
V a = [1, 2, 3]
V b = Set([1, 2, 3])
V i = 4
L n > a.len
I i !C b & gcd(i, a.last) == 1 & gcd(i, a[(len)-2]) > 1
a.append(i)
b.add(i)
i = 4
i++
R a
print(yellow(30))