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 A239935 #17 Jul 03 2021 04:20:30 %S A239935 11,14,15,18,20,27,29,31,34,38,41,43,47,48,50,53,54,58,59,63,64,65,67, %T A239935 69,71,72,75,77,79,83,88,90,94,98,99,102,103,107,109,112,114,118,119, %U A239935 123,125,131,132,134,136,139,141,142,146,150,154,159,161,164,167 %N A239935 Numbers k such that DigitSum(3^k) > DigitSum(3^(k+1)). %H A239935 Robert Israel, <a href="/A239935/b239935.txt">Table of n, a(n) for n = 1..8009</a> %e A239935 For k=11, we have DigitSum(3^11) = 27 > 18 = DigitSum(3^12). %p A239935 N:= 1000: # to get the first N terms %p A239935 threen:= 3: %p A239935 digsum:= 3: %p A239935 count:= 0: %p A239935 for n from 1 while count < N do %p A239935 threen:= 3*threen; %p A239935 oldsum:= digsum; %p A239935 digsum:= convert(convert(threen,base,10),`+`); %p A239935 if oldsum > digsum then %p A239935 count:= count+1; %p A239935 A239935[count]:= n; %p A239935 fi %p A239935 od: # _Robert Israel_, Apr 18 2014 %t A239935 lis = Table[Total[IntegerDigits[3^n, 10]], {n, 1, 100}]; %t A239935 Flatten[Position[Greater @@@ Partition[lis, 2, 1], True]] %o A239935 (PARI) isok(k) = sumdigits(3^k) > sumdigits(3^(k+1)); \\ _Michel Marcus_, Jul 03 2021 %Y A239935 Cf. A004166, A007953. %K A239935 nonn,base %O A239935 1,1 %A A239935 _Oliver Bel_, Mar 29 2014 %E A239935 More terms from _Jon E. Schoenfield_, Mar 29 2014