login

Year-end appeal: Please make a donation to the OEIS Foundation to support ongoing development and maintenance of the OEIS. We are now in our 61st year, we have over 378,000 sequences, and we’ve reached 11,000 citations (which often say “discovered thanks to the OEIS”).

A136691
Final nonzero digit of n! in base 4.
16
1, 1, 2, 2, 2, 2, 1, 3, 2, 2, 3, 1, 3, 3, 2, 2, 2, 2, 3, 1, 1, 1, 2, 2, 3, 3, 2, 2, 2, 2, 1, 3, 2, 2, 3, 1, 1, 1, 2, 2, 1, 1, 2, 2, 2, 2, 3, 1, 3, 3, 2, 2, 2, 2, 3, 1, 2, 2, 3, 1, 3, 3, 2, 2, 2, 2, 3, 1, 1, 1, 2, 2, 1, 1, 2, 2, 2, 2, 3, 1, 1, 1, 2, 2, 2, 2, 1, 3, 2, 2, 1, 3, 1, 1, 2, 2, 3, 3, 2, 2
OFFSET
0,3
LINKS
EXAMPLE
6! = 720 decimal = 23100 quartal, so a(6) = 1.
MATHEMATICA
nzd[n_]:=Module[{rd=RealDigits[n!, 4][[1]]}, If[Last[rd]!=0, Last[rd], Last[ Flatten[Most[Split[rd]]]]]]; Array[nzd, 100, 0] (* Harvey P. Dale, May 08 2014 *)
KEYWORD
base,easy,nonn
AUTHOR
Carl R. White, Jan 16 2008
STATUS
approved