whats my error?

```
t = int(input())
for i in range(t):
n=int(input())
ls = list(map(int, input().split()))
arr=[]
for i in range(n):
arr.append(ls[i])
count = 1
for i in range(len(arr)-1):
if arr[i]>arr[i+1] or arr[i] == arr[i+1]:
count+=1
print(count)
```