0,1

Table of n, a(n) for n=0..107.

No power of 2 ends with 3, so the first term is 2.

No power of 2 is == 22 mod 100, since 4 does not divide 22, so the next term is 3 (and 4 does divide 32).

No power of 2 is == 332 mod 1000, since 8 does not divide 332, so the next term is 2 (and 8 does divide 232). And so on.

Cf. A023410, A053316.

Sequence in context: A159580 A121549 A244228 * A258115 A296658 A175066

Adjacent sequences: A023394 A023395 A023396 * A023398 A023399 A023400

nonn,base

David W. Wilson

approved