#include <iostream>
#include<vector>
#include<algorithm>
using namespace std;

int main(){
int n;cin>>n;
  int h1,h2,c,ans;
  cin>>h1;
  ans=c=0;
  for(int i=0;i<n-1;i++){
  	cin>>h2;
    if(h1<h2){
      c=0;
    }else{c++;}
    ans=max(c,ans);
  	h1=h2;
  }
  cout <<ans<<endl;
  
}