## S001071

Numbers n such that the digits of 1 to n concatenated in some order is possibly a palindrome.

1, 19, 20, 21, 22, 39, 40, 41, 59, 60, 61, 79, 80, 81, 98, 99, 101, 119, 121, 122, 139, 141, 159, 161, 179, 181, 199, 201, 219, 220, 221, 239, 241, 259, 261, 279, 281, 299, 301, 319, 321, 339, 341, 359, 361, 379, 381, 399, 401, 419, 421, 439, 440, 441, 459

1

The digits of each number are kept together. So for the first non-trivial case, the palindrome is the concatenation of the numbers 1..19 in some order. The center digit of the resulting palindrome must be a 0 because a count of the digits on the numbers 1..19 is {1, 12, 2, 2, 2, 2, 2, 2, 2, 2}.

T. D. Noe, Plot of 1000 terms

T. D. Noe, Table of 1000 terms

(Mma) t2 = {}; n = 0; While[Length[t2] < 50, n++; d = IntegerDigits /@ Range[n]; ds = Sort[Flatten[d]]; tds = Transpose[Tally[ds]][[2]]; If[OddQ[Length[ds]] && Count[tds, _?(OddQ[#] &)] == 1 || EvenQ[Length[ds]] && Count[tds, _?(OddQ[#] &)] == 0, AppendTo[t2, n]]]; t2

Cf. S001070.

nonn,base

T. D. Noe, Sep 01 2017

© Tony D Noe 2014-2017