It's IIKI's birthday today. He got a function called INSERTER as a gift from OIIKI, one of his mathematician friends. Initially, he has an empty array. With the function, he can perform the following operations on this array.
1 x idx— insert value x at index idx
2 k idx— insert k-th smallest element of the array at index idx
$Q$ operations and informed you details of each operation. Can you print the final array?
Note that, first operation is always of first type.
The first line contains one integer
$Q$ — the number of operations performed. Each of the following
$Q$ lines contains the description of the operation.
$Q \leqslant 2×10^5$
$x \leqslant 10^9$
$k \leqslant array.size()\ before\ operation\ $
$idx \leqslant array.size()\ before\ operation\ $
Print the final array after performing all the operations.
5 1 7 0 1 5 1 2 2 2 2 1 0 1 3 2
5 7 3 5 7