fun main(args: Array<String>) {
    val n = readLine()!!.toInt()
    val heights = readLine()!!.split(" ").map(String::toInt)
    var max = 0
    val indexes = mutableListOf(0)
    for (i in 1.until(n)) {
        if (heights[i -1] < heights[i]) {
            indexes.add(i)
            val ren = indexes.last() - indexes[indexes.size - 2] - 1
            if (ren > max) {
                max = ren
            }
        }
    }
    println(Math.max(max, heights.size - indexes.last() - 1))
}