practivceAlgorithm/백준
[백준][Python] 2920 음계
findTheValue
2021. 10. 23. 22:13
오름차순이면 ascending
반대면 descending
둘다 아니면 mixed
arr = list(map(int, input().split()))
pivot = [i for i in range(1, 9)]
if arr == pivot:
print('ascending')
elif arr == pivot[::-1]:
print('descending')
else:
print('mixed')