login
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.
1

%I #9 Dec 23 2021 08:34:38

%S 12,23,34,45,56,67,78,89,101,112,120,121,122,123,124,125,126,127,128,

%T 129,134,145,156,167,178,189,201,212,223,230,231,232,233,234,235,236,

%U 237,238,239,245,256,267,278,289,301,312,323,334,340,341,342,343,344,345

%N 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.

%C Corrected by Zak Seidov, Apr 15 2007

%H Michael S. Branicky, <a href="/A098953/b098953.txt">Table of n, a(n) for n = 1..10000</a>

%o (Python)

%o from itertools import count, islice

%o def cond(n):

%o d = list(map(int, str(n)))

%o return any(d[i+1] == d[i]+1 for i in range(len(d)-1))

%o def agen():

%o yield from filter(cond, count(1))

%o print(list(islice(agen(), 54))) # _Michael S. Branicky_, Dec 23 2021

%Y A similar sequence: A082927

%K base,easy,nonn

%O 1,1

%A _Eric Angelini_, Oct 21 2004

%E a(51) and beyond from _Michael S. Branicky_, Dec 23 2021