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 A082208 #17 Jun 24 2022 04:44:49 %S A082208 0,1,2,3,4,5,6,7,8,9,11,22,33,44,101,111,121,131,141,151,161,171,191, %T A082208 202,212,222,232,242,252,272,303,313,323,333,353,404,414,434,515,787, %U A082208 868,949,1001,1111,1221,1331,2002,2112,2222,2992,3003,3113,3883,4004 %N A082208 Palindromes for which the sum of the digits is also a palindrome. %e A082208 4774 is in the sequence because (1) it is a palindrome and (2) the sum of its digits 4 + 7 + 7 + 4 = 22 is also a palindrome. %p A082208 rev := proc (n) local nn; nn := convert(n, base, 10): add(nn[j]*10^(nops(nn)-j), j = 1 .. nops(nn)) end proc: sd := proc (n) options operator, arrow: add(convert(n, base, 10)[j], j = 1 .. nops(convert(n, base, 10))) end proc: a := proc (n) if rev(n) = n and rev(sd(n)) = sd(n) then n else end if end proc: seq(a(n), n = 0 .. 5000); # _Emeric Deutsch_, Jan 18 2009 %t A082208 d[n_]:=IntegerDigits[n]; sod[n_]:=Total[d[n]]; palQ[n_]:=Reverse[x=d[n]]==x; t={}; Do[If[palQ[n] && palQ[sod[n]],AppendTo[t,n]],{n,0,4005}]; t (* _Jayanta Basu_, May 15 2013 *) %o A082208 (Python) %o A082208 from itertools import chain, count, islice %o A082208 def A082208_gen(): # generator of terms %o A082208 return filter(lambda n:(s:=str(sum(int(d) for d in str(n))))[:(t:=(len(s)+1)//2)]==s[:-t-1:-1],chain((0,),chain.from_iterable(chain((int((s:=str(d))+s[-2::-1]) for d in range(10**l,10**(l+1))), (int((s:=str(d))+s[::-1]) for d in range(10**l,10**(l+1)))) for l in count(0)))) %o A082208 A082208_list = list(islice(A082208_gen(),20)) # _Chai Wah Wu_, Jun 23 2022 %Y A082208 Cf. A002113, A082207. %K A082208 base,nonn %O A082208 1,3 %A A082208 _Amarnath Murthy_, Apr 10 2003 %E A082208 More terms from Luc Stevens (lms022(AT)yahoo.com), Apr 16 2006; corrected Apr 18 2006; corrected Apr 20 2006 %E A082208 Edited by _N. J. A. Sloane_, Jan 14 2009 at the suggestion of _Ian Kent_