#include<bits/stdc++.h>
using namespace std;
int n;
int main(){
    cin>>n;int h[n+1];for(int i=0;i<n;i++)cin>>h[i];h[n]=1000000001;
    int ans=0,cnt=0;
    for(int i=0;i<=n;i++){
        if(h[i]>=h[i+1])cnt++;
        else {ans=max(ans,cnt);cnt=0;}
    }
    cout<<ans<<endl;
    }