import java.math.*

fun main(args: Array<String>) {
    val n = readInputLine().toInt()
    // 整数として扱えるように1000倍する
    val (t, a) = readInputLine().split(" ").map{it.toInt() * 1000}
    
    val hs = readInputLine().split(" ").map{it.toInt()}
    
    var diff = Int.MAX_VALUE
    var ans = 0
    
    for ((i, h) in hs.withIndex()) {
        val hDiff = Math.abs(a - t + h * 6)
        
        if (hDiff < diff) {
            diff = hDiff
            ans = i + 1
        }
    }
    
    println(ans)
}

fun readInputLine(): String {
    return readLine()!!
}
