integer N
integer(16),allocatable,dimension(:)::H
integer ans,preans
read*,N
allocate(H(N))
read*,H
ans=0;preans=0
do i=1,N-1
  if(H(i)>=H(i+1))then
    preans=preans+1
  else
    ans=max(ans,preans)
    preans=0
  endif
end do
ans=max(ans,preans)
print"(i0)",ans
end