[go: up one dir, main page]

login
Non-palindromic number and its reversal are both even.
1

%I #13 Oct 10 2020 12:15:05

%S 20,24,26,28,40,42,46,48,60,62,64,68,80,82,84,86,200,204,206,208,210,

%T 214,216,218,220,224,226,228,230,234,236,238,240,244,246,248,250,254,

%U 256,258,260,264,266,268,270,274,276,278,280,284,286,288,290,294,296

%N Non-palindromic number and its reversal are both even.

%e 24 and 42 are both multiples of 2.

%t Select[Range[2,296,2],EvenQ[Last[x=Reverse[y=IntegerDigits[#]]]] && x!=y &] (* _Jayanta Basu_, May 17 2013 *)

%o (ARIBAS): n := 2; stop := 410; m := 0; while m < stop do rev := int_reverse(m); if m <> rev and rev mod n = 0 then write(m," "); end; inc(m,n); end;.

%o (PARI) isok(m) = {if (!(m%2), my(r=fromdigits(Vecrev(digits(m)))); if ((r!=m) && !(r%2), print1(m, ", ")););} \\ _Michel Marcus_, Oct 10 2020

%Y Cf. A029742 (non-palindromic), A005843 (even numbers).

%K nonn,base,easy

%O 1,1

%A _Amarnath Murthy_, Jul 01 2001

%E More terms from _Dean Hickerson_, Jul 06, 2001