We have an empty sequence $A$.
Given $Q$ queries, process them in order.
Each query is of one of the following three types.
* `1 x` : Insert $x$ to $A$.
* `2 x k` : Among the elements of $A$ that are less than or equal to $x$, print the $k$\-th largest value. ($k$ is no more than $\bf{5}$)
If there are less than $k$ elements of $A$ that are less than or equal to $x$, then print `-1`.
* `3 x k` : Among the elements of $A$ that are greater than or equal to $x$, print the $k$\-th smallest value. ($k$ is no more than $\bf{5}$)
If there are less than $k$ elements of $A$ that are greater than or equal to $x$, then print `-1`.
## Constraints
* $1\leq Q \leq 2\times 10^5$
* $1\leq x\leq 10^{18}$
* $1\leq k\leq 5$
* All values in input are integers.
## Input
Input is given from Standard Input in the following format:
$Q$
$\text{query}_1$
$\text{query}_2$
$\vdots$
$\text{query}_Q$
In the $i$\-th query $\text{query}_i$, the type of query $c_i$ (which is either $1, 2$, or $3$) is given first.
If $c_i=1$, then $x$ is additionally given; if $c_i=2, 3$, then $x$ and $k$ are additionally given.
In other words, each query is given in one of the following three formats:
$1$ $x$
$2$ $x$ $k$
$3$ $x$ $k$
[samples]