OFFSET
1,1
COMMENTS
In the concatenation of all terms of this sequence, "201101234567892013...", consider the digits '1' as delimiters of chunks of other digits, "20", "", "0", "2345678920", .... The lengths of these chunks are given by the terms of the sequence.
LINKS
E. Angelini, To reach the next "1", SeqFan list, August 10, 2015.
EXAMPLE
The sequence cannot start with a(1) = 0, which would imply starting with a chunk of 0 digits different from '1', i.e., a digit '1': contradiction. It also cannot start with a(1) = 1, which would require starting with a string of 1 digit different from '1': contradiction. So it has to start with a(1) = 2 digits different from '1'.
The smallest possible choice for the next term is a(2) = 0.
Then, the first '1' must occur as a(3) = 1, and be immediately followed by another digit '1', whence a(4) = 10, in order to have a(2) = 0 digits different from 1 in between them.
Then, there is a(3) = 1 digit different from '1' until the next '1', occurring in a(5) = 12.
PROG
(PARI) A261161(n=99, d=1, a=2, p=0, u=[-1], r=u)={for(n=1, n, print1(a", "); p+=#digits(a)+!a; r=concat(r, r[#r]+a+1); while(#r>1&&r[1]<p, r=r[2..-1]); u=setunion(u, [a]); while(#u>1&&u[2]==u[1]+1, u=u[2..-1]); for(k=u[1]+1, 9e9, setsearch(u, k)&&next; if( r[1] >= p+#dk=if(k, digits(k), [0]), setsearch(Set(dk), d)&&next, for(i=1, #dk, (dk[i]==d)==!setsearch(r, p+i-1)&&next(2))); a=k; next(2)); error); a}
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Eric Angelini and M. F. Hasler, Aug 10 2015
STATUS
approved