use std::cmp::max;
use std::io::prelude::*;
use std::io::stdin;
use std::str::FromStr;

fn main() {
    let n: usize = read();
    let h: Vec<i32> = (0..n).map(|_| read()).collect();

    let mut max_i = 0;
    let mut count = 0;
    for h in h.windows(2) {
        if h[0] >= h[1] {
            count += 1;
        } else {
            max_i = max(max_i, count);
            count = 0;
        }
    }
    max_i = max(count, max_i);

    println!("{}", max_i);
}

#[allow(dead_code)]
fn read<T: FromStr>() -> T {
    let stdin = stdin();
    let token: String = stdin
        .lock()
        .bytes()
        .map(|b| b.unwrap() as char)
        .skip_while(|c| c.is_whitespace())
        .take_while(|c| !c.is_whitespace())
        .collect();
    token.parse().ok().unwrap()
}
