let n = Int(readLine()!)!
let array = readLine()!.characters.split{$0 == " "}.map{ Int(String($0))! }

var ret = 0
var current = 0
var last = array[0]

for i in 0..<array.count {
  if i != 0 {
    if array[i] <= last {
      current += 1
    } else {
      ret = max(ret, current)
      current = 0
    }
  }
  last = array[i]
}

ret = max(ret, current)

print(ret)