Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
95177 胡皓宇 找错误 Python3 Accepted 223 MS 9724 KB 202 2024-10-27 09:35:38

Tests(10/10):


Code:

i = int(input()) a = list(map(int,input().split())) c = 0 _ = 0 while _<i-1: if a[_]>a[_+1]: c = c + 1 del(a[_+1]) i = i - 1 _ = _ - 1 _ = _+1 print(c)