%I #13 Jun 15 2018 11:38:38
%S 1,1,1,2,2,4,3,5,6,9,8,11,11,11,16,17,17,18,23,23,28,31,33,27,33,29,
%T 40,37,42,42,41,44,47,44,53,56,57,50,64,55,59,68,63,72,70,61,69,85,80,
%U 83,87,97,98,101,87,91,100,102,114,108,116,109,117,117,113,124
%N Number of ones in Zeckendorf representation of n!
%H Chai Wah Wu, <a href="/A182577/b182577.txt">Table of n, a(n) for n = 0..10000</a>
%e 5! = {1, 0, 0, 1, 0, 1, 0, 0, 1, 0} in the Zeckendorf base.
%o (Python)
%o from math import factorial
%o def A182577(n):
%o m, tlist, s = factorial(n), [1,2], 0
%o while tlist[-1]+tlist[-2] <= m:
%o tlist.append(tlist[-1]+tlist[-2])
%o for d in tlist[::-1]:
%o if d <= m:
%o s += 1
%o m -= d
%o return s # _Chai Wah Wu_, Jun 15 2018
%Y Cf. A007895, A020908, A020910, A025496-A025502, A182535, A182576, A000142.
%K nonn
%O 0,4
%A _Alex Ratushnyak_, May 05 2012
|