login
A383246
Positive integers without the digit 0 such that every even digit except the rightmost is immediately followed by a smaller digit.
8
1, 2, 3, 4, 5, 6, 7, 8, 9, 11, 12, 13, 14, 15, 16, 17, 18, 19, 21, 31, 32, 33, 34, 35, 36, 37, 38, 39, 41, 42, 43, 51, 52, 53, 54, 55, 56, 57, 58, 59, 61, 62, 63, 64, 65, 71, 72, 73, 74, 75, 76, 77, 78, 79, 81, 82, 83, 84, 85, 86, 87, 91, 92, 93, 94, 95, 96, 97, 98, 99
OFFSET
1,2
COMMENTS
Conjecture: these are the terms of A342043, sorted.
MATHEMATICA
A383246Q[k_] := FreeQ[#, 0] && FreeQ[Partition[#, 2, 1], {i_?EvenQ, j_} /; j >= i] & [IntegerDigits[k]];
Select[Range[200], A383246Q]
PROG
(Python)
def ok(n):
s = str(n)
return "0" not in s and all(d not in "02468" or s[i]<d for i, d in enumerate(s, 1) if i < len(s))
print([k for k in range(100) if ok(k)]) # Michael S. Branicky, Apr 28 2025
CROSSREFS
KEYWORD
nonn,base,easy
AUTHOR
Paolo Xausa, Apr 20 2025
STATUS
approved