Module Module1

    Sub Main()

        Dim N As Integer = Console.ReadLine()
        Dim arr As String() = Split(Console.ReadLine())
        Dim x As Integer
        Dim ar(N) As Long
        Dim i As Integer
        Dim kaisu As Integer = 0
        Dim saidai As Integer = 0

        For x = 0 To N - 1
            ar(x) = CLng(arr(x))
        Next

        kaisu = 0
        For x = N - 1 To 1 Step -1
            If ar(x - 1) >= ar(x) Then
                kaisu += 1
            Else
                If saidai < kaisu Then
                    saidai = kaisu
                End If
                kaisu = 0
            End If
            If kaisu > saidai Then
                saidai = kaisu
            End If
        Next

        Console.WriteLine(saidai)

        'Console.ReadLine()

    End Sub

End Module
