Exists or Not Exists

You will be given some numbers. Then there will contain some queries. In every query there will be given a range and a number. You have to say that, the given number exists in the range of values or not.

This is a companion discussion topic for the original entry at https://toph.co/p/exists-or-not-exists