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 A007961 #15 Jul 25 2015 15:52:48 %S A007961 1,2,3,10,11,12,13,20,100,101,102,103,110,111,112,1000,1001,1002,1003, %T A007961 1010,1011,1012,1013,1020,10000,10001,10002,10003,10010,10011,10012, %U A007961 10013,10020,10100,10101,100000,100001,100002,100003,100010,100011 %N A007961 n written in base where place values are positive squares. %C A007961 For n>1: A000196(n) = number of digits of a(n); A190321(n) = number of nonzero digits of a(n); A053610(n) = sum of digits of a(n). [_Reinhard Zumkeller_, May 08 2011] %H A007961 Reinhard Zumkeller, <a href="/A007961/b007961.txt">Table of n, a(n) for n = 1..10000</a> %H A007961 F. Smarandache, <a href="http://www.gallup.unm.edu/~smarandache/OPNS.pdf">Only Problems, Not Solutions!</a>. %p A007961 A007961 := proc(n) %p A007961 local k,nrem,L,b,d; %p A007961 k := floor(sqrt(n)) ; %p A007961 nrem := n ; %p A007961 L := [] ; %p A007961 for b from k to 1 by -1 do %p A007961 d := floor(nrem/b^2) ; %p A007961 L := [d,op(L)] ; %p A007961 nrem := nrem -d*b^2 ; %p A007961 end do: %p A007961 add( op(i,L)*10^(i-1),i=1..nops(L)) ; %p A007961 end proc: # _R. J. Mathar_, Jul 25 2015 %o A007961 (Haskell) %o A007961 import Data.Char (intToDigit) %o A007961 a007961 :: Integer -> Integer %o A007961 a007961 n = read $ map intToDigit $ %o A007961 t n $ reverse $ takeWhile (<= n) $ tail a000290_list where %o A007961 t _ [] = [] %o A007961 t m (x:xs) %o A007961 | x > m = 0 : t m xs %o A007961 | otherwise = (fromInteger m') : t r xs %o A007961 where (m',r) = divMod m x %o A007961 -- _Reinhard Zumkeller_, May 08 2011 %Y A007961 Cf. A000290, A000433. %K A007961 nonn,base %O A007961 1,2 %A A007961 R. Muller