This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A330536 #22 Jan 14 2020 12:07:31 %S A330536 2,1,4,6,24,22,8,42,28,60,26,46,44,40,68,66,112,158,64,86,84,118,62, %T A330536 88,20,48,156,114,136,138,132,150,116,82,192,176,190,392,198,172,152, %U A330536 178,240,206,174,282,244,80,154,242,204,202,228,170,246,130,648,110,756,196,194,222,208,266,286,284,280,200 %N A330536 The partial sum a(1)+...+a(n) is prime, and so is the sum of the digits used by those n terms. %C A330536 This is the lexicographically earliest sequence of distinct numbers > 0 with this property. %H A330536 Carole Dubois, <a href="/A330536/b330536.txt">Table of n, a(n) for n = 1..5000</a> %H A330536 Carole Dubois, <a href="/A330536/a330536.jpg">Graph and trend curves for terms, digits sums, terms sums</a> %H A330536 Rémy Sigrist, <a href="/A330536/a330536.txt">C++ program for A330536</a> %e A330536 The successive partial sums of terms are prime: %e A330536 (2), (2 + 1) = 3, (2 + 1 + 4) = 7; (2 + 1 + 4 + 6) = 13; (2 + 1 + 4 + 6 + 24) = 37; etc. %e A330536 The successive partial sums of their digits are also prime: %e A330536 (2), (2 + 1) = 3, (2 + 1 + 4) = 7; (2 + 1 + 4 + 6) = 13; (2 + 1 + 4 + 6 + 2 + 4) = 19; etc. %t A330536 Nest[Append[#, Block[{k = 1}, While[Nand[FreeQ[#, k], PrimeQ[Total@ # + k], PrimeQ@ Total@ Flatten@ IntegerDigits[Append[#, k]]], k++]; k]] &, {}, 68] (* _Michael De Vlieger_, Dec 17 2019 *) %o A330536 (C++) See Links section. %Y A330536 Cf. A054408 (smallest positive integer not already in sequence such that the partial sum a(1)+...+a(n) is prime). %K A330536 base,nonn %O A330536 1,1 %A A330536 _Eric Angelini_ and _Carole Dubois_, Dec 17 2019