function Main(input) {
  lines = input.split("\n");
  N= lines[0] * 1
  h = lines[1].split(' ').map(function(x) {
      return x * 1
  })
  n = h[0] * 1;
  cnt = 0;
  max = 0;
  for (i = 1; i < h.length; i++) {
      r = h[i] * 1
      if (n >= r) {
          cnt++
      } else {
          if (max < cnt) {
              max = cnt
          }
          cnt = 0
      }
      n = r
  }
  if (max < cnt) {
      max = cnt
  }
  console.log(max)
}
Main(require("fs").readFileSync("/dev/stdin", "utf8"));
