|
|
A288945
|
|
Starting with a(1) = 1, a(n) = smallest nonnegative integer not yet in the sequence such that the first digit of a(n) is the last digit of a(n-1) plus or minus 1, with preference given to -1 when possible. The digit 0 is not allowed.
|
|
1
|
|
|
1, 2, 11, 21, 22, 12, 13, 23, 24, 3, 25, 4, 31, 26, 5, 41, 27, 6, 51, 28, 7, 61, 29, 8, 71, 211, 212, 14, 32, 15, 42, 16, 52, 17, 62, 18, 72, 19, 81, 213, 214, 33, 215, 43, 216, 53, 217, 63, 218, 73, 219, 82, 111, 221, 222, 112, 113, 223, 224, 34, 35, 44, 36, 54
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
COMMENTS
|
If a(n-1) ends in 1, a(n) must begin with 2 (i.e., a forced increase by 1).
There are no numbers in the sequence with first digit 9.
|
|
LINKS
|
|
|
EXAMPLE
|
11 is followed by 21 in the sequence since it can't be followed by a number starting with 0.
|
|
CROSSREFS
|
|
|
KEYWORD
|
nonn,base
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|