cp's OEIS Frontend

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.

A338840 No even digit is present in a(n) + a(n+1).

This page as a plain text file.
%I A338840 #17 Nov 20 2020 21:56:38
%S A338840 0,1,2,3,4,5,6,7,8,9,10,21,12,19,14,17,16,15,18,13,20,11,22,29,24,27,
%T A338840 26,25,28,23,30,41,32,39,34,37,36,35,38,33,40,31,42,49,44,47,46,45,48,
%U A338840 43,50,61,52,59,54,57,56,55,58,53,60,51,62,69,64,67,66,65,68,63,70,81,72,79,74,77,76,75,78,73
%N A338840 No even digit is present in a(n) + a(n+1).
%C A338840 This is the lexicographically earliest sequence of distinct nonnegative terms with this property and also a permutation of the nonnegative integers.
%H A338840 Carole Dubois, <a href="/A338840/b338840.txt">Table of n, a(n) for n = 1..5001</a>
%H A338840 <a href="/index/Per#IntegerPermutation">Index entries for sequences that are permutations of the nonnegative integers</a>
%e A338840 a(1) + a(2) = 0 + 1 = 1 (no even digit is present);
%e A338840 a(2) + a(3) = 1 + 2 = 3 (no even digit is present);
%e A338840 a(3) + a(4) = 2 + 3 = 5 (no even digit is present);
%e A338840 ...
%e A338840 a(6) + a(7) = 5 + 6 = 11 (no even digit is present); etc.
%t A338840 Block[{a = {0}}, Do[Block[{k = 1}, While[Nand[FreeQ[a, k], NoneTrue[IntegerDigits@ Total[a[[-1]] + k], EvenQ]], k++]; AppendTo[a, k]], {i, 2, 80}]; a] (* _Michael De Vlieger_, Nov 12 2020 *)
%Y A338840 Cf. A014261 (no even digits).
%Y A338840 Cf. A338839, A338841, A338842, A338843, A338844, A338845, A338846 (variants on the same idea).
%K A338840 base,nonn
%O A338840 1,3
%A A338840 _Eric Angelini_ and _Carole Dubois_, Nov 11 2020