repl.it
@pCoding/

example-102

Python

No description

fork
loading
Files
  • main.py
main.py
1
2
3
4
5
6
7
8
9
10
11
A = [5, 1, 6, 7, 8, 8, 7, 7, 6, 9]
c = 0
for i in range(1, 10):
	if A[i-1]>=A[i]:
		t = A[i]
		A[i] = A[i-1]
		A[i-1] = t
	else:
		c = c + 1

print(c)
Fetching token
?