A228410 The digits of a(n) and a(n+1) together can be reordered to form a palindrome; lexicographically least injective sequence of positive integers with this property.
1, 10, 100, 11, 2, 12, 21, 102, 20, 101, 22, 3, 13, 31, 103, 30, 110, 33, 4, 14, 41, 104, 40, 114, 24, 42, 112, 23, 32, 113, 34, 43, 131, 35, 5, 15, 51, 105, 50, 115, 25, 52, 121, 26, 6, 16, 61, 106, 60, 116, 36, 63, 136, 163, 316, 361, 613, 631, 1003, 111, 17, 7, 27, 72, 117, 37, 73, 137, 71, 107
Offset: 1
Links
- Lars Blomberg, Table of n, a(n) for n = 1..10000
- E. Angelini, Re: Two make a palindrome, SeqFan list, Nov 09 2013
Programs
-
PARI
{u=0; a=1; for(n=1,99, u+=1<
-
Python
from collections import Counter A228410_list, l, s, b = [1], Counter('1'), 2, set() for _ in range(10**2): i = s while True: if i not in b: li, o = Counter(str(i)), 0 for d in (l+li).values(): if d % 2: if o > 0: break o += 1 else: A228410_list.append(i) l = li b.add(i) while s in b: b.remove(s) s += 1 break i += 1 # Chai Wah Wu, Dec 14 2014
Comments