CodeEff/ECCO huggingface dataset:
# Original solution
n = int(eval(input()))
h = list(map(int, input().split()))
temp = 0
for i in range(n-1):
    a = 0
    while i+a+1 < n and h[i+a]>=h[i+a+1]:
        a += 1
        temp = max(temp, a)
print(temp)

# Optimized solution
n = int(eval(input()))
h = list(map(int, input().split()))
temp = 0
i = 0
while i<n:
    a = 0
    while i+a+1 < n and h[i+a]>=h[i+a+1]:
        a += 1
        temp = max(temp, a)
    if a == 0: i+=1
    else: i+=a
print(temp)
# Original solution
N=int(eval(input()))
H=list(map(int,input().split()))
ans=0
for i in range(N-1):
  tmp=0
  for j in range(i,N-1):
    if H[j] >= H[j+1]:
      tmp += 1
    else:
      break
  ans = max(ans,tmp)
print(ans)

# Optimized solution
N=int(eval(input()))
H=list(map(int,input().split()))
ans=0
i = 0

while i < N-1:
  tmp=0
  for j in range(i,N-1):
    if H[j] >= H[j+1]:
      tmp += 1
    else:
      break
  ans = max(ans,tmp)
  i = i + tmp +1
print(ans)
# Original solution
n = int(eval(input()))
h = list(map(int,input().split()))

res = []
for i in range(n):
  count = 0
  flag = True
  for j in range(i,n-1):
    if h[j] >= h[j+1]:
      if flag:
      	count += 1
    else:
      flag = False
      break
  res.append(count)
      
print((max(res)))

# Optimized solution
n = int(eval(input()))
h = list(map(int,input().split()))

res = []
count = 0
for i in range(n-1):
  if h[i] >= h[i+1]:
    count += 1
    if i == (n-2):
      res.append(count)
  else:
    if count != 0: 
      res.append(count)
    count = 0

if len(res) == 0:
  print((0))
else:
  print((max(res)))
# Original solution
n = int(eval(input()))
h = list(map(int, input().split()))

h_max = -1
ind = -1
cnt = -1
ans = -1
for i in range(n - 1, -1, -1):
    if h[i] >= h_max:
        ind = i
        h_max = h[i]
        cnt += 1
        ans = max(ans, cnt)
    else:
        h_max = h[i]
        cnt = 0
print(ans)


# Optimized solution
def main():
    N = int(eval(input()))

    ans = 0
    t = -1
    p = 1 << 30
    for h in map(int, input().split()):
        if p >= h:
            t += 1
            if ans < t:
                ans = t
        else:
            t = 0
        p = h

    print(ans)


if __name__ == '__main__':
    main()
# Original solution
N = int(eval(input()))
lis_h = list(map(int, input().split()))

count = 0
max_move = 0
before = 0

for i in lis_h:
      if i <= before:
            count += 1
            if max_move < count:
                  max_move = count
      else:
            count = 0
      before = i
print(max_move)
            

# Optimized solution
n = int(eval(input()))
L = list(map(int,input().split()))

c = 0
mc = 0
for i in range(1,n):
      if L[i - 1] >= L[i]:
            c += 1
            if c >= mc:
                  mc = c
      else:
            c = 0
print(mc)
# Original solution
n=int(eval(input()))
h= list(map(int,input().split()))
count=[0]*n

for t in range(n):
    for i in range(t,n-1):
        if h[i]>=h[i+1]:
            count[t]+=1
        else:
            break

print((max(count)))


# Optimized solution
n=int(eval(input()))
h= list(map(int,input().split()))

COU=0
m_max=0
for i in h:
    if i>COU:
        m=0
    else:
        m+=1
        if m>m_max:
            m_max=m
    
    COU=i
print(m_max)
# Original solution
N = int(eval(input()))
Hs = list(map(int, input().split()))
res = [0] * N

for index, h in enumerate(Hs):
    l = 0
    #if index > 0:
    #    l = max(res[index - 1] - 1, 0)

    tmp = h
    while index + l + 1 < N and tmp >= Hs[index + l + 1]:
        tmp = Hs[index + l + 1]
        l += 1
    res[index] = l

print((max(res)))

# Optimized solution
N = int(eval(input()))
Hs = list(map(int, input().split()))
res = [0] * N

for index, h in enumerate(Hs):
    l = 0
    if index > 0:
        l = max(res[index - 1] - 3, 0)

    tmp = h
    while index + l + 1 < N and tmp >= Hs[index + l + 1]:
        tmp = Hs[index + l + 1]
        l += 1
    res[index] = l

print((max(res)))
# Original solution
N = int(eval(input()))
Hs = list(map(int, input().split()))
res = [0] * N

for index, h in enumerate(Hs):
    l = 0
    if index > 0:
        l = max(res[index - 1] - 3, 0)

    tmp = h
    while index + l + 1 < N and tmp >= Hs[index + l + 1]:
        tmp = Hs[index + l + 1]
        l += 1
    res[index] = l

print((max(res)))

# Optimized solution
N = int(eval(input()))
Hs = list(map(int, input().split()))
res = [0] * N

for index, h in enumerate(Hs):
    l = 0
    if index > 0:
        l = max(res[index - 1] - 2, 0)

    tmp = h
    while index + l + 1 < N and tmp >= Hs[index + l + 1]:
        tmp = Hs[index + l + 1]
        l += 1
    res[index] = l

print((max(res)))
# Original solution
import sys
from math import pi, cos, sqrt
from collections import defaultdict
readline = sys.stdin.buffer.readline
#sys.setrecursionlimit(10**8)


def geta(fn=lambda s: s.decode()):
    return list(map(fn, readline().split()))


def gete(fn=lambda s: s.decode()):
    return fn(readline().rstrip())


def main():
    n = gete(int)
    h = tuple(geta(int))

    ans = 0

    cur = 0
    for i in range(n - 1):
        if h[i] >= h[i + 1]:
            cur += 1
            if cur > ans:
                ans = cur
        else:
            cur = 0

    print(ans)


if __name__ == "__main__":
    main()

# Optimized solution
import sys
from math import pi, cos, sqrt
from collections import defaultdict
readline = sys.stdin.buffer.readline
#sys.setrecursionlimit(10**8)


def geta(fn=lambda s: s.decode()):
    return list(map(fn, readline().split()))


def gete(fn=lambda s: s.decode()):
    return fn(readline().rstrip())


def main():
    n = gete(int)
    h = list(geta(int))
    h += [10**10]

    cur = 0
    ans, tmp = 0, 0
    while cur < n:
        if h[cur] >= h[cur + 1]:
            tmp += 1
        else:
            if tmp > ans:
                ans = tmp
            tmp = 0
        cur += 1
    print(ans)


if __name__ == "__main__":
    main()
# Original solution
if __name__ == "__main__":
    b = int(eval(input()))
    a = list(map(int, input().split()))
    a = a[::-1]
    count = 0
    value = 0
    for i in range(1, b):
        if a[i-1] <= a[i]: count+=1
        else: count = 0
        value = max(count, value)
    print(value)
    

# Optimized solution
n = eval(input())
a = list(map(int, input().split()))
#b = list(map(int, input().split()))
#c = list(map(int, input().split()))
m = 0
c = 0
for i in range(1, len(a)):
    if a[i] <= a[i-1]:
        c += 1
        m = max(m, c)
    else:
        c = 0
print(m)
# Original solution
#!usr/bin/env python3
from collections import defaultdict,deque
from heapq import heappush, heappop
import sys
import math
import bisect
import random
def LI(): return [int(x) for x in sys.stdin.readline().split()]
def I(): return int(sys.stdin.readline())
def LS():return [list(x) for x in sys.stdin.readline().split()]
def S():
    res = list(sys.stdin.readline())
    if res[-1] == "\n":
        return res[:-1]
    return res
def IR(n):
    return [I() for i in range(n)]
def LIR(n):
    return [LI() for i in range(n)]
def SR(n):
    return [S() for i in range(n)]
def LSR(n):
    return [LS() for i in range(n)]

sys.setrecursionlimit(1000000)
mod = 1000000007

#A
def A():
    s = S()
    t = S()
    ans = 0
    for i in range(len(s)):
        if s[i] == t[i]:
            ans += 1
    print(ans)
    return

#B
def B():
    a,b = LI()
    for i in range(10000):
        if 1+i*a-i >= b:
            print(i)
            return
    return

#C
def C():
    n = I()
    a = LI()
    ans = 0
    r = 1
    for l in range(n):
        if r == l:
            r += 1
        while r < n and a[r-1] >= a[r]:
            r += 1
        ans = max(ans, r-l-1)
    print(ans)
    return

#D
def D():

    return

#E
def E():

    return

#F
def F():

    return

#Solve
if __name__ == "__main__":
    C()


# Optimized solution
#!usr/bin/env python3
from collections import defaultdict, deque
from heapq import heappush, heappop
from itertools import permutations, accumulate
import sys
import math
import bisect
def LI(): return [int(x) for x in sys.stdin.readline().split()]
def I(): return int(sys.stdin.readline())
def LS():return [list(x) for x in sys.stdin.readline().split()]
def S():
    res = list(sys.stdin.readline())
    if res[-1] == "\n":
        return res[:-1]
    return res
def IR(n):
    return [I() for i in range(n)]
def LIR(n):
    return [LI() for i in range(n)]
def SR(n):
    return [S() for i in range(n)]
def LSR(n):
    return [LS() for i in range(n)]

sys.setrecursionlimit(1000000)
mod = 1000000007

def solve():
    n = I()
    h = LI()[::-1]
    ans = 0
    i = 0
    while i < n:
        j = i+1
        while j < n and h[j] >= h[j-1]:
            j += 1
        m = j-i-1
        if ans < m:
            ans = m
        i = j
    print(ans)
    return

#Solve
if __name__ == "__main__":
    solve()
# Original solution
n=int(eval(input()))
h=list(map(int,input().split()))
ans=0
for i in range(n):
    cnt=0
    step=h[i]
    for j in range(i+1,n):
        if step<h[j]: break
        step=h[j]
        cnt+=1
    ans=max(ans,cnt)
print(ans)

# Optimized solution
n=int(eval(input()))
if n==1:print('0'); exit()
h=list(map(int,input().split()))
ans=0
step=0
for i in range(n):
    cnt=0
    for j in range(n):
        if h[step]<h[step+1]: step+=1; break
        cnt+=1; step+=1
        if step+1==n: break
    ans=max(ans,cnt)
    if step+1==n: break
print(ans)
# Original solution
n=int(eval(input()))
ans=0
now=input().split()
a=0
for i in range(len(now)-1):
    if int(now[i])>=int(now[i+1]):
        a+=1
    else :
        a=0
    # print(a)
    ans=max(ans,a)
print(ans)

# Optimized solution
from sys import stdin
n=int(stdin.readline())
ans=0
now=list(map(int,stdin.readline().split()))
a=0
for i in range(len(now)-1):
    if now[i]>=now[i+1]:
        a+=1
    else :
        a=0
    # print(a)
    ans=max(ans,a)
print(ans)
# Original solution
N = int(eval(input()))
H = list(map(int,input().split()))

stp = [0]*(N+1)
stp[0] = 0

for i in range(1,N):
    if H[i]<=H[i-1]:
        stp[i] = stp[i-1] +1
    else:
        stp[i] = 0
        
print((max(stp)))

# Optimized solution
N = int(eval(input()))
h = list(map(int,input().split()))
memo = [0]*N
for i in range(1,N):
    if h[i]<=h[i-1]:
        memo[i] = memo[i-1] + 1 
print((max(memo)))
# Original solution
n = int(eval(input()))
hh = list(map(int, input().split()))

ans = 0
for i in range(n - 1, 0, -1):
    x = 1
    while i + x < n and hh[i + x - 1] >= hh[i + x]:
        x += 1
    ans = max(ans, x - 1)
print(ans)


# Optimized solution
n = int(eval(input()))
h = list(map(int, input().split()))

ans = 0
x = 0
for i in range(1, n):
    if h[i - 1] >= h[i]:
        x += 1
    else:
        x = 0
    ans = max(ans, x)
print(ans)
# Original solution
N=int(eval(input()))
*H,=list(map(int,input().split()))


i=0
cnt=0
ans=0
while i < N-1:
    if 1<=H[i]/H[i+1]:
        cnt+=1
    else:
        ans=max(ans,cnt)
        cnt=0
    i+=1
ans=max(ans,cnt)
print(ans)

# Optimized solution
N=int(eval(input()))
*H,=list(map(int,input().split()))


i=cnt=ans=0
while i<N-1:
 if 1<=H[i]/H[i+1]:
   cnt+=1
 else:
   ans=max(ans,cnt)
   cnt=0
 i+=1
print((max(ans,cnt)))
# Original solution
N = int(eval(input()))
H = list(map(int, input().split()))
def move_right(i):
    count = 0
    for j in range(i, N-1):
        if H[j+1]<=H[j]:
            count += 1
        else:
            break
    return count

answer=0

for i in range(N-1):
    answer=max(answer,move_right(i))

print(answer)


# Optimized solution
N = int(eval(input()))
H = list(map(int, input().split()))
count = 0
answer = 0
for j in range(N-1):
    if H[j+1] <= H[j]:
        count += 1
    else:
        answer = max(count, answer)
        count = 0
answer = max(count, answer)
print(answer)
# Original solution
n = int(eval(input()))
H = list(map(int,input().split()))
ans = 0

for i in range(n):
    tmp = 0
    for j in range(i,n):
        if j == i:
            continue
        if H[j] <= H[j-1]:
            tmp += 1
        else:
            break
    ans = max(ans,tmp)

print(ans)

# Optimized solution
n = int(eval(input()))
h = list(map(int,input().split()))
ans = 0
tmp = 0

for i in range(n-1):
    if h[i+1] <= h[i]:
        tmp += 1
    else:
        ans = max(ans,tmp)
        tmp = 0

print((max(ans,tmp)))
# Original solution
N = int(eval(input()))
H = list(map(int, input().split()))
q = 0
s = [0]
for i in range(N-1):
  if H[i] >= H[i+1]:
    p = q + 1
    s.append(p)
    q = q + 1
  else:
    s.append(0)
    q = 0

s.sort()
ans = s[-1]
print(ans)

# Optimized solution
N = int(eval(input()))
H = list(map(int, input().split()))
old = H[0]
ans = 0
a = 0
for i in range(1,N):
  if H[i] <= old:
    a += 1
  else:
    if a > ans:
      ans = a
    a = 0
  old = H[i]
if a > ans:
  ans = a
print(ans)
# Original solution
n = int(eval(input()))
a = [int(a) for a in input().split()]
aans =0
for i in range(n):
  ans=0
  for ii in range (i,n-1):
    if a[ii] >= a[ii+1]:
      ans +=1
    else:
      break
  if ans >aans:
    aans =ans
print(aans)
    
    

# Optimized solution
n = int(eval(input()))
a = [int(a) for a in input().split()]
aans =0
ans =0
for i in range(n-1):
  if a[i] >= a[i+1]:
    ans +=1
  else :
    if ans >aans:
      aans =ans
      ans = 0
    else :
      ans =0
if ans >aans:
  aans =ans
print(aans)
# Original solution
N = int(eval(input()))
H = list(map(int, input().split()))
ans = 0
start = 0

while ( start < N ):
    tmp_ans = 0
    for j in range(start, N-1):
        if (H[j] >= H[j+1]):
            tmp_ans += 1
        else:
            start += tmp_ans
            break
            
    ans = max(ans, tmp_ans)
    start += 1
    
print(ans)

# Optimized solution
N = int(eval(input()))
H = list(map(int, input().split()))
ans = [0]

for i in range(0, len(H)-1):
    if (H[i] >= H[i+1]):
        ans.append(ans[i]+1)
    else:
        ans.append(0)

print((max(ans)))
# Original solution
# question 3
N = eval(input())
H = input().split()

# question 3
i = 0

for n in range(0, int(N)-1):
  j = 0
  
  for h in range(n, int(N)-1):
    if int(H[h]) < int(H[h+1]):
      break
    j += 1      
  
  if i < j:
    i = j
    
  if i >= int(N) - n:
    break
    
print(i)


# Optimized solution
# question 3
N = eval(input())
H = input().split()

# question 3
i = 0
res = [0]

for n in range(0, int(N)-1):
  if int(H[n]) >= int(H[n+1]):
    i += 1
  else:
    res.append(i)
    i = 0

res.append(i)
    
print((max(res)))
# Original solution
N = int(eval(input()))
H_list = input().split(" ")
max_count = 0
for i in range(0, N):
    S = int(H_list[i])
    count = 0
    for j in range(i + 1, N):
        if S >= int(H_list[j]):
            S = int(H_list[j])
            count += 1
        else:
            break
    if max_count < count:
        max_count = count
    if max_count >= N - i -1:
        break
    if max_count >= N / 2:
        break
print(max_count)



# Optimized solution
N = int(eval(input()))
H_LIST = input().split(" ")
H = []

for i in H_LIST:
    H.append(int(i))
   
count = 0
max_count = 0
for i in range(0, N-1):
    if H[i] >= H[i + 1]:
        count += 1
    else:
        count = 0 #メモリの動き
        
    if max_count < count:
        max_count = count


print(max_count)
# Original solution
def main():
    n = int(eval(input()))
    h = list(map(int, input().split()))
    ans = 0
    for i in range(n - 1):
        j = i
        count = 0
        while j < n-1:
            # print(h[j])
            # print(h[j + 1])
            # print("=====")
            if h[j] >= h[j + 1]:
                count += 1
                j += 1
                ans = max(ans, count)
            else:
                # ans = max(ans, count)
                break
    print(ans)


if __name__ == "__main__":
    main()


# Optimized solution
def main():
    n = int(eval(input()))
    h = list(map(int, input().split()))
    ans = 0
    max_list = [0]
    for i in range(n - 1):
        if h[i] >= h[i + 1]:
            ans += 1
            max_list.append(ans)
        else:
            ans = 0
    print((max(max_list)))


if __name__ == "__main__":
    main()
# Original solution
n = int(eval(input()))
h = list(map(int, input().split()))

out, cnt = 0, 0
for i in range(n-1):
    if h[i] >= h[i+1]:
        cnt += 1
        out = max(out, cnt)
    else:
        cnt = 0

print(out)


# Optimized solution
n = int(eval(input()))
h = list(map(int, input().split()))

cnt = 0
result = 0
for i in range(n-1):
    if h[i] - h[i+1] >= 0:
        cnt += 1
    else:
        result = max(cnt, result)
        cnt = 0

result = max(cnt, result)

print(result)
# Original solution
n,*h=list(map(int,open(0).read().split()));c=[0]
for i,j in zip(h,h[1:]):c+=[(i>=j)*-~c[-1]]
print((max(c)))

# Optimized solution
n,h=open(0);a=b=c=0
for i in map(int,h.split()):c=(b>=i)*-~c;b=i;a=max(a,c)
print(a)
# Original solution
n = int(eval(input()))
h = list(map(int, input().split()))
clm = [0] * n

for i in range(n):
    for j in range(i, n-1):
        if h[j] >= h[j+1]:
            clm[i] += 1
        else:
            break


print((max(clm)))

# Optimized solution
n = int(eval(input()))
h = list(map(int, input().split()))

count = 0
maxcount = 0
for i in range(n-1):
    if h[i] >= h[i+1]:
        count += 1
        maxcount = max(count, maxcount)
    else:
        count = 0

print(maxcount)
# Original solution
n = int(eval(input()))
h = list(map(int, input().split()))

count = 0
maxcount = 0
for i in range(n-1):
    if h[i] >= h[i+1]:
        count += 1
        maxcount = max(count, maxcount)
    else:
        count = 0

print(maxcount)

# Optimized solution
n = int(eval(input()))
h = list(map(int, input().split()))

count = 0
maximum = 0
for i in range(n-1):
    if h[i] >= h[i+1]:
        count += 1
    else:
        maximum = max(count,maximum)
        count = 0
maximum = max(count,maximum)
print(maximum)
# Original solution
n = int(eval(input()))
integers = list(map(int, input().split()))

max_moves = 0
moves = 0
for i in range(n-1):
    for k in range(i, n-1):
        if integers[k] >= integers[k+1]:
            moves += 1
        else:
            break
    if max_moves < moves:
        max_moves = moves
    moves = 0
    if max_moves > n-i-1:
        break
print(max_moves)


# Optimized solution
n = int(eval(input()))
integers = list(map(int, input().split()))

max_moves = 0
moves = 0
for i in range(n-1):
    if integers[i] >= integers[i+1]:
        moves += 1
    else:
        moves = 0
    if max_moves < moves:
        max_moves = moves
print(max_moves)
# Original solution
N = int(eval(input()))
H = list(map(int, input().split()))

result = 0
tempres = 0
for i in range(0, N):
    for j in range(i, N - 1):
        if H[j] >= H[j + 1]:
            tempres += 1
        else:
            break
    result = max(result, tempres)
    i += tempres
    tempres = 0
    if result >= N - i - 1:
        break
print(result)


# Optimized solution
N = int(eval(input()))
H = list(map(int, input().split()))

result = 0
tempres = 0
for i in range(0, N):
    if tempres != 0:
        tempres -= 1
        continue
    for j in range(i, N - 1):
        if H[j] >= H[j + 1]:
            tempres += 1
        else:
            break
    result = max(result, tempres)
    if result >= N - i - 1:
        break
print(result)
# Original solution
N = int(eval(input()))
H = list(map(int, input().split()))

result = 0

for i in range(N-1):
    ans = 0
    for j in range(N-i-1):
        if H[i + j] >= H[i + j + 1]: 
            ans += 1
        else:
            break
    if result <= ans:
        result = ans

print(result)

# Optimized solution
N = int(eval(input()))
H = list(map(int, input().split()))
ans = 0
result = 0

for i in range(N-1):
    if H[i] >= H[i+1] and i == N-2:
        ans += 1
        if result < ans:
            result = ans
    elif H[i] >= H[i+1]:
        ans +=1
    else:
        if result < ans:
            result = ans
        ans = 0

print(result)
# Original solution
# -*- coding: utf-8 -*-
"""
Created on Wed Mar 25 10:13:10 2020

@author: Kanaru Sato
"""

N = int(eval(input()))
H = list(map(int, input().split()))
ans = 0
count = 0

for i in range(0,N-1):
    if H[i] >= H[i+1]:
        count += 1
        ans = max(ans,count)
    else:
        count = 0

print(ans)

# Optimized solution
# -*- coding: utf-8 -*-
"""
Created on Wed Mar 25 10:13:10 2020

@author: Kanaru Sato
"""

N = int(eval(input()))
H = list(map(int, input().split()))
record = 0
count = 0

for i in range(0,N-1):
    if H[i] >= H[i+1]:
        count += 1
    else:
        record = max(count,record)
        count = 0

ans = max(record,count)

print(ans)
# Original solution
N=int(eval(input()))
Hi=list(map(int,input().split()))

ans=[0]*N

for i in range (N):
    a=0
    if Hi[i]<Hi[i-1]:
        continue

    for j in range(N-i-1):
        if Hi[i+j]>=Hi[i+j+1]:
            a+=1
        else:
            break
    ans[i]=a

print((max(ans)))

# Optimized solution
N=int(eval(input()))
Hi=list(map(int,input().split()))

# ans=[0]*N

# for i in range (N):
#     a=0
#     # if Hi[i]<Hi[i-1]:
#     #     continue
#     for j in range(N-i-1):
#         if Hi[i+j]>=Hi[i+j+1]:
#             a+=1
#         else:
#             break
#     ans[i]=a

# print(max(ans))

ans=0
temp=0

for i in range(1,N):
    if Hi[i]<=Hi[i-1]:
        temp+=1
    else:
        if temp>ans:
            ans=temp
        else:
            pass
        temp=0
else:
    if temp>ans:
        ans=temp

print(ans)
# Original solution
N = int(eval(input()))
H = [int(x) for x in input().split()]
dp = [0] * len(H) 
for i in range(1, len(H)):
  if H[i-1] >= H[i]: 
    dp[i] = dp[i-1] + 1
ans = max(dp)
print(ans)

# Optimized solution
N = int(eval(input())) #解答
H = list(map(int,input().split()))
L = [0] * N
for i in range(N-2,-1,-1):
    if H[i] >= H[i+1]:
        L[i] = L[i+1] + 1
print((max(L)))
# Original solution
N = int(eval(input()))
h =list(map(int,input().split()))
L = [0] * N

for i in range(N-2,-1,-1):
  if h[i] >= h[i+1]:
    L[i] = L[i+1] + 1
    
print((max(L)))

# Optimized solution
N = int(eval(input()))
H = [int(i) for i in input().split()]
rem=0
cnt=0
for i in range(N-1):
    if H[i] >= H[i+1]:
        cnt+=1
    else:
        rem=max(rem,cnt)
        cnt=0
rem=max(rem,cnt)
print(rem)
# Original solution
def num(pos,list1):
    count = 0
    val = list1[pos]
    for x in range(pos+1,len(list1)):
        if list1[x]<=val:
            count+=1
            val=list1[x]
        else:
            return count
    return count
maximum = 0
n = int(eval(input()))
list1 = [int(i) for i in input().split()]
for y in range(len(list1)):
    ans = num(y,list1)
    if ans>maximum:
        maximum = ans
print(maximum)

# Optimized solution
def num(pos,list1):
    count = 0
    val = list1[pos]
    for x in range(pos+1,len(list1)):
        if list1[x]<=val:
            count+=1
            val=list1[x]
        else:
            return count
    return count
maximum = 0
n = int(eval(input()))
list1 = [int(i) for i in input().split()]
y = 0
while y<len(list1):
    ans = num(y,list1)
    if ans>maximum:
        maximum = ans
    y+=ans+1
print(maximum)
# Original solution
n = int(eval(input()))
h = list(map(int, input().split()))
answer = 0#これなに
m = 0#カウントするやつやね
for i in range(n-1):
    if h[i] >= h[i+1]:
        m += 1
    else:
        answer = max(answer,m)
        m = 0
answer = max(answer,m)
print(answer)


# Optimized solution
n = int(eval(input()))
h = list(map(int,input().split(" ")))
plsl = []
plsn = 0
for i in range(n-1):
    if h[i]>= h[i+1]:
        plsn += 1
    else: #i<i+1の時
        plsl.append(plsn)
        plsn = 0
plsl.append(plsn)
plsl.sort(reverse = True)
print((plsl[0]))
# Original solution
N = int(eval(input()))
H = list(map(int, input().split()))

if N == 1:
    print((0))
else:
    ans = 0
    H1 = H[0]
    H2 = H[1]
    count = 1
    move = 0
    while count != N:
        count += 1
        if H2 <= H1:
            move += 1
            ans = max(ans, move)
        else:
            move = 0
        if count != N:
            H1 = H2
            H2 = H[count]

    print(ans)


# Optimized solution
N = int(eval(input()))
H = list(map(int, input().split()))

ans = 0
count = 0
for i in range(N - 1):
    if H[i] >= H[i + 1]:
        count += 1
        ans = max(ans, count)
    else:
        count = 0

print(ans)