A105516 Number of times 6 is the leading digit of the first n+1 Fibonacci numbers in decimal representation.
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6
Offset: 0
Links
- Winston de Greef, Table of n, a(n) for n = 0..10000
Crossrefs
Programs
-
Mathematica
Prepend[Accumulate[If[First[IntegerDigits[#]]==6,1,0]&/@Fibonacci[ Range[ 110]]],0] (* Harvey P. Dale, Feb 18 2011 *)
-
PARI
(leadingdigit(n, b=10) = n \ 10^logint(n, b)); (isok(n) = leadingdigit(fibonacci(n))==6); (lista(n)=my(a=vector(1+n), r=0); for (i=1, n, r+=isok(i); a[1+i]=r); a) \\ Winston de Greef, Mar 17 2023