A336206 Lexicographically earliest sequence of nonnegative terms such that whenever a(k_1) = ... = a(k_m) with k_1 < ... < k_m, the sum k_1 + ... + k_m can be computed without carries in base 10.
0, 0, 0, 1, 1, 2, 3, 4, 5, 0, 0, 0, 2, 6, 6, 7, 8, 9, 10, 0, 3, 7, 11, 11, 12, 13, 14, 15, 16, 0, 3, 8, 12, 17, 17, 18, 19, 20, 21, 1, 4, 11, 13, 22, 22, 23, 24, 25, 26, 1, 7, 14, 18, 27, 28, 29, 30, 31, 32, 2, 9, 19, 33, 34, 35, 36, 37, 38, 39, 5, 15, 40, 41
Offset: 1
Examples
We can choose a(1) = a(2) = a(3) = 0 as 1 + 2 + 3 = 6 can be computed without carries. However 1 + 2 + 3 + 4 implies a carry, so a(4) = 1.
Links
- Rémy Sigrist, Table of n, a(n) for n = 1..10000
- Rémy Sigrist, Scatterplot of the first 100000 terms
- Rémy Sigrist, C program for A336206
Programs
-
C
See Links section.
Formula
a(n) = 0 iff n belongs to A278742.
Comments