OFFSET
1,10
COMMENTS
a(n) = A120004(n) for n <= 100. a(101) = #{0, 1, 10, 11, 101} = 5; a(102) = #{0, 1, 2, 10, 12, 102} = 6. - Reinhard Zumkeller, Jun 15 2006
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
EXAMPLE
a(124)=7 and the numbers are 1,2,4,12,14,24,124.
MAPLE
f:= proc(n) local L, V;
L:= convert(n, base, 10);
V:= convert(map(t -> L[t], combinat:-powerset([$1..nops(L)])), set) minus {[]};
V:= map(proc(t) local i; add(t[i]*10^(i-1), i=1..nops(t)) end proc, V);
nops(select(t -> t <= n, V))
end proc:
map(f, [$1..100]); # Robert Israel, Dec 03 2024
CROSSREFS
KEYWORD
base,easy,nonn
AUTHOR
Amarnath Murthy, Feb 04 2003
EXTENSIONS
More terms from Antonio G. Astudillo (afg_astudillo(AT)lycos.com), Apr 19 2003
Corrected and extended by Reinhard Zumkeller, Jun 15 2006
STATUS
approved
