시간 제한메모리 제한제출정답맞힌 사람정답 비율
2 초 256 MB30131038.462%

문제

Peter had written a string of length n composed of 0-s and 1-s on a blackboard. After that he looked at all pairs of adjacent characters and found out that there are a pairs 00, b pairs 01, c pairs 10 and d pairs 11 (a + b + c + d = n - 1).

Bad boy Gregory has erased the string. After some sad thoughts Peter now wants to restore some string that has the same number for all types of adjacent pairs of characters. Help him!

입력

There are several tests in one input. The first line contains an integer t (1 ≤ t ≤ 10 000) — the number of tests.

Each test is described in one line that contains four integers: a, b, c and d (0 ≤ a, b, c, d ≤ 20) — the number of adjacent pairs 00, 01, 10 and 11, respectively.

It is guaranteed that a + b + c + d ≥ 1.

출력

Output t lines. For each test output the string that satisfies the conditions, or impossible if there is no such string.

 

예제 입력 1

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

예제 출력 1

10
impossible
00110
0001110
11111001010