n, t, e = gets.chomp.split.map(&:to_i)
arr = gets.chomp.split.map(&:to_i)
answer = -1
arr.sort.uniq.each{|x|
    [(t.to_f / x).floor, (t.to_f / x).ceil].each{|q|
        if (q * x).between?(t - e, t + e)
            answer = arr.index(x) + 1
            break
        end
    }
    break if answer != -1
}
puts answer
