PROGRAMMING:A cunning rich man
The old housekeeper is a smart and capable man. He worked for a rich man for 10 years, who wanted to make his accounts clearer. The housekeeper is required to account K times a day. Because the housekeeper is smart and capable, the housekeeper always satisfies the rich man. However, due to some people's provocation, the rich man still had doubts about the housekeeper. So he decided to use a special method to judge the housekeeper's loyalty. He numbered each account by 1, 2, 3... And then asked the housekeeper from time to time. The question is: what is the minimum amount in account a to B? In order to make the housekeeper have no time to cheat, he always asks many questions at one time.
###Input format:
There are two numbers m in the first line of input, n means there are m (m < = 100000) accounts, n means there are n problems, n < = 100000.
The second line is the number m, which is the amount of money in the account
The following N lines are n questions, and each line has 2 numbers to indicate the account number at the beginning and end.
###Output format:
Output the answer for each question in the file. See the sample for details.
###Input example:
Here is a set of inputs. For example:
```in
10 3
1 2 3 4 5 6 7 8 9 10
2 7
3 9
1 10
```
###Output example:
The corresponding output is given here. For example:
```out
two
three
one
```
answer:If there is no answer, please comment
###Input format:
There are two numbers m in the first line of input, n means there are m (m < = 100000) accounts, n means there are n problems, n < = 100000.
The second line is the number m, which is the amount of money in the account
The following N lines are n questions, and each line has 2 numbers to indicate the account number at the beginning and end.
###Output format:
Output the answer for each question in the file. See the sample for details.
###Input example:
Here is a set of inputs. For example:
```in
10 3
1 2 3 4 5 6 7 8 9 10
2 7
3 9
1 10
```
###Output example:
The corresponding output is given here. For example:
```out
two
three
one
```
answer:If there is no answer, please comment