N = int(input())
hlist = [int(x) for x in input().split()]
count = 0
for idx in range(0, len(hlist)-1):
    #print(idx)
    if hlist[idx] <= hlist[idx + 1]:
        #print("途中",idx)
        count += 1
    else:
        if idx == 0:
            count = 1
        else:
            pass
print(count)