%I
%S 0,1,2,3,4,5,6,7,8,9,10,11,12,21,22,23,32,33,34,43,44,45,54,55,56,65,
%T 66,67,76,77,78,87,88,89,98,99,100,101,102,110,111,112,120,121,122,
%U 130,131,132,140,141,142,150,151,152,160,161,162,170,171,172,180
%N Nonnegative integers n such that the difference between n and its reverse is a palindrome.
%C a(n) = A178403(n) for n < 48. [_Reinhard Zumkeller_, May 27 2010]
%p filter:= proc(n) local L,nL,r;
%p L:= convert(n,base,10);
%p nL:= nops(L);
%p r:= add(L[i]*10^(nLi),i=1..nL);
%p L:= convert(abs(nr),base,10);
%p evalb(L = ListTools:Reverse(L))
%p end proc:
%p select(filter, [$0..1000]); # _Robert Israel_, Aug 26 2014
%t revpalQ[n_]:=Module[{diff=IntegerDigits[Abs[nFromDigits[Reverse[ IntegerDigits[ n]]]]]},diff==Reverse[diff]]; Select[Range[ 0,400],revpalQ] (* _Harvey P. Dale_, Aug 22 2014 *)
%o (Java) for(i = 1; i <=1000; i++){ n = Math.abs(i  reverseNumber(i)); if(n == reverseNumber(n)){ System.out.println(i); } }
%K nonn,base
%O 1,3
%A Rachit Agrawal (rachit_agrawal(AT)daiict.ac.in), Oct 23 2007
%E Corrected by _Harvey P. Dale_, Aug 22 2014
