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 A022481 #21 Jul 07 2017 17:24:51 %S A022481 1,11,12,2111,1321,11213111,1331112112,211221133211,12213212221221, %T A022481 11221123112131112211,122213311121123121122212, %U A022481 211123122111312112211332112311 %N A022481 Describe previous term from the right (method B - initial term is 1). %C A022481 Method B = 'digit'-indication followed by 'frequency'. %H A022481 Reinhard Zumkeller, <a href="/A022481/b022481.txt">Table of n, a(n) for n = 1..24</a> %e A022481 E.g. the term after 1321 is obtained by saying "1 once, 2 once, 3 once, 1 once", which gives 11213111. %t A022481 A022481[1]:=1;A022481[n_]:=A022481[n]=FromDigits[Flatten[{First[#],Length[#]}&/@Split[Reverse[IntegerDigits[A022481[n-1]]]]]];Map[A022481,Range[15]] (* _Peter J. C. Moses_, Apr 22 2013 *) %t A022481 a[1]=1;a[n_]:=a[n]=FromDigits[Flatten[Replace[ Replace[ Replace[ Split[ Reverse[IntegerDigits[a[n-1]]]],{x_,y_}->{x,Length[{x,y}]},{1}],{x_,y_,z_}->{x,Length[{x,y,z}]},{1}],{x_}->{x,Length[{x}]},{1}]]];Array[a,15] (* _Ivan N. Ianakiev_, Jun 22 2017 *) %t A022481 NestList[FromDigits@ Flatten@ Reverse@ Map[{First@ #, Length@ #} &, Split@ IntegerDigits@ #] &, 1, 11] (* _Michael De Vlieger_, Jun 26 2017 *) %o A022481 (Haskell) %o A022481 import Data.List (group, transpose) %o A022481 a022481 n = a022481_list !! (n-1) %o A022481 a022481_list = 1 : f [1] :: [Integer] where %o A022481 f xs = (read $ concatMap show ys) : f ys where %o A022481 ys = concat $ transpose [map head zss, map length zss] %o A022481 zss = reverse $ group xs %o A022481 -- _Reinhard Zumkeller_, Jan 26 2014 %Y A022481 Cf. A022488, A022514, A022515, A022516, A022517, A022518, A022519, A022520. %K A022481 nonn,base,easy,nice %O A022481 1,2 %A A022481 _Clark Kimberling_