A336954 Lexicographically earliest sequence of distinct positive terms such that, in the concatenation of the decimal representations of the terms, for any digit d at position p, d appears at some position q such that abs(p-q) = d.
1, 10, 2, 3, 20, 30, 4, 5, 6, 7, 40, 50, 60, 70, 8, 9, 11, 12, 32, 83, 90, 22, 220, 21, 13, 33, 333, 23, 24, 25, 34, 43, 52, 42, 26, 27, 28, 36, 63, 71, 18, 61, 14, 29, 240, 31, 130, 91, 15, 35, 53, 54, 55, 44, 37, 430, 41, 17, 45, 38, 93, 51, 16, 48, 49, 46
Offset: 1
Examples
For n = 1: - we can choose a(1) = 1. For n = 2: - a(2) must start with a digit 1, - we can choose a(2) = 10. For n = 3: - we can choose a(3) = 2. For n = 4: - we can choose a(4) = 3. For n = 5: - a(5) must start with a digit 2, - we can choose a(5) = 20.
Links
- Rémy Sigrist, Table of n, a(n) for n = 1..10000
- Rémy Sigrist, PARI program for A336954
Programs
-
PARI
\\ See Links section.
Comments