

A098159


Numbers n with property that when writing down all the nonnegative numbers from 0 to n one uses n odd digits.


0



1, 17, 18, 20, 21, 37, 38, 40, 41, 57, 58, 60, 61, 77, 78, 80, 81, 97, 98
(list;
graph;
refs;
listen;
history;
text;
internal format)



OFFSET

1,2


COMMENTS

The sequence seems to stop at 98.


LINKS

Table of n, a(n) for n=1..19.


EXAMPLE

[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17] uses 17 odd digits.


MATHEMATICA

f[n_] := Block[{id = Mod[ Flatten[ Table[ IntegerDigits[i], {i, 0, n}]], 2]}, Plus @@ id]; Select[ Range[ 100], f[ # ] == # &] (* Robert G. Wilson v, Nov 03 2004 *)


CROSSREFS

Sequence in context: A043870 A296865 A188049 * A241847 A295487 A308888
Adjacent sequences: A098156 A098157 A098158 * A098160 A098161 A098162


KEYWORD

base,easy,nonn,fini,full


AUTHOR

Eric Angelini, Oct 25 2004


STATUS

approved



