OFFSET
1,6
LINKS
Harvey P. Dale, Table of n, a(n) for n = 1..1000
FORMULA
EXAMPLE
a1(11)=3 as 11th prime, 31, is 1011 in base 3 representation.
MATHEMATICA
a1[n_] := Length[Cases[IntegerDigits[Prime[n], 3], 1]]
Table[DigitCount[n, 3, 1], {n, Prime[Range[100]]}] (* Harvey P. Dale, Feb 23 2015 *)
CROSSREFS
KEYWORD
base,easy,nonn
AUTHOR
Zak Seidov Aug 11 2002
STATUS
approved