This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A081608 #13 Oct 21 2024 15:34:33 %S A081608 0,1,2,2,3,4,4,5,6,6,6,6,6,7,8,8,9,10,10,10,10,10,11,12,12,13,14,14, %T A081608 14,14,14,14,14,14,14,14,14,14,14,14,15,16,16,17,18,18,18,18,18,19,20, %U A081608 20,21,22,22,22,22,22,22,22,22,22,22,22,22,22,22,23,24,24,25,26,26,26,26 %N A081608 Number of numbers <= n having no 0 in their ternary representation. %C A081608 a(n) + A081607(n) = n+1. %H A081608 Winston de Greef, <a href="/A081608/b081608.txt">Table of n, a(n) for n = 0..16383</a> %t A081608 Accumulate[Table[If[DigitCount[n,3,0]==0,1,0],{n,0,80}]] (* _Harvey P. Dale_, Oct 21 2024 *) %o A081608 (PARI) first(n)=my(s,t); vector(n,k, t=Set(digits(k,3)); s+=!!t[1]) \\ _Charles R Greathouse IV_, Sep 02 2015 %Y A081608 Cf. A007089, A077267, A061392, A081611. %K A081608 nonn %O A081608 0,3 %A A081608 _Reinhard Zumkeller_, Mar 23 2003