[go: up one dir, main page]

login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
Search: a043502 -id:a043502
Displaying 1-1 of 1 result found. page 1
     Sort: relevance | references | number | modified | created      Format: long | short | data
A316864 Number of times 3 appears in decimal expansion of n. +10
9
0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,34
LINKS
FORMULA
From Robert Israel, Dec 10 2019: (Start)
a(10*n+3) = a(n)+1, a(10*n+i)=a(i) for i = 0,1,2,4..9.
G.f. g(z) satisfies g(z) = z^3/(1-z^10) + ((1-z^10)/(1-z))*g(z^10). (End)
EXAMPLE
a(0) = 0 since the decimal representation of 0 does not contain the digit 3.
a(3) = 1 since 3 appears once in the decimal expansion of 3.
MAPLE
f:= proc(n) option remember;
procname(floor(n/10)) + `if`(n mod 10 = 3, 1, 0)
end proc:
for i from 0 to 9 do f(i):= `if`(i=3, 1, 0) od:
map(f, [$0..100]); # Robert Israel, Dec 10 2019
MATHEMATICA
Array[ DigitCount[#, 10, 3] &, 105, 0]
PROG
(PARI) a(n) = #select(x->x==3, digits(n)); \\ Michel Marcus, Jul 20 2018
CROSSREFS
KEYWORD
base,easy,nonn
AUTHOR
Robert G. Wilson v, Jul 15 2018
STATUS
approved
page 1

Search completed in 0.006 seconds

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified August 30 09:28 EDT 2024. Contains 375532 sequences. (Running on oeis4.)