cf/mirror

Arthur and Brackets

CF
508E2200· master2s128 MB⌨ stdin/stdout

Examples

Sample 1of 4
Input
4
1 1
1 1
1 1
1 1
Output
()()()()
Sample 2of 4
Input
3
5 5
3 3
1 1
Output
((()))
Sample 3of 4
Input
3
5 5
3 3
2 2
Output
IMPOSSIBLE
Sample 4of 4
Input
3
2 3
1 4
1 4
Output
(())()
508E.cpp
loading editor…
Ln 11·137 BGNU C++20 (64)