def more_or_less_one(number: int) -> str:
n = str(number)
A = 1
result = []
for i in range(0, len(n), A):
result.append(int(n[i: i + A]))
for x in range(1, len(result) +1):
print(x)
if result[x - 1] + 1 == result[x] or result[x + 1] - result[x] == 1:
retrun True
more_or_less_one(23454)
def more_or_less_one(number: int) -> str:
return str(not any([abs(int(str(number)[x]) - int(str(number)[x+1]))-1 for x in range(len(str(number))-1)]))
data = 234543
print(more_or_less_one(data))
data = 234564
print(more_or_less_one(data))