A098953 Slowest increasing sequence where each number is such that at least one pair of adjacent digits are consecutive, the first of the pair being the smaller.
12, 23, 34, 45, 56, 67, 78, 89, 101, 112, 120, 121, 122, 123, 124, 125, 126, 127, 128, 129, 134, 145, 156, 167, 178, 189, 201, 212, 223, 230, 231, 232, 233, 234, 235, 236, 237, 238, 239, 245, 256, 267, 278, 289, 301, 312, 323, 334, 340, 341, 342, 343, 344, 345
Offset: 1
Links
- Michael S. Branicky, Table of n, a(n) for n = 1..10000
Crossrefs
A similar sequence: A082927
Programs
-
Python
from itertools import count, islice def cond(n): d = list(map(int, str(n))) return any(d[i+1] == d[i]+1 for i in range(len(d)-1)) def agen(): yield from filter(cond, count(1)) print(list(islice(agen(), 54))) # Michael S. Branicky, Dec 23 2021
Extensions
a(51) and beyond from Michael S. Branicky, Dec 23 2021
Comments