n = gets.to_i
h = gets.split.map(&:to_i)
result = 0
cnt = 0
(1..n-1).each do |i|
  if h[i-1] >= h[i]
    cnt += 1
  else
    if result < cnt 
      result = cnt
    end
    cnt = 0
  end
end
 if result < cnt 
	result = cnt
 end
puts result