There are N points located on the X axis at positions A1,A2,…,AN respectively. Alice performs (N−1) journeys. During the ith journey (1≤i≤N−1), Alice moves from ith point to (i+1)th point (i.e from position Ai to position Ai+1).
You have to answer Q queries of the following form:
Input format
Output format
For each query, print the answer in a separate line.
Constraints
2≤N,Q≤2⋅1051≤Ai,Xi≤109Ai≠Ai+11≤Li≤Ri≤N−1Xi≠Aj(1≤i≤Q,1≤j≤N)
Query 1: During the 1st journey and 3rd journey Alice goes over point 5.
Query 2: During the 4th Alice goes over point 11.
Query 3: During the 3rd and 4th journey Alice goes over point 7.
Query 4: During the 1st, 2nd, and 4th journey Alice goes over point 9.