1722: 区间排序 - CCF-GESP2024年9月四级C++

Memory Limit:128 MB Time Limit:1.000 S
Judge Style:Text Compare Creator:
Submit:12 Solved:7

Description

Input

Output

Sample Input Copy

5
3 4 5 2 1
3
4 5
3 4
1 3

Sample Output Copy

1 3 4 5 2