fun main(args: Array<String>) {
    val N = readLine()!!.toInt()
    val H = readLine()!!.split(" ").map(String::toInt)
    var high = 0
    var p = 0
    H.forEach { h ->
        if (high > h) return@forEach
        high = h
        p++
    }
    println(p)
}