시간 제한 메모리 제한 제출 정답 맞은 사람 정답 비율
1 초 128 MB 48 24 23 54.762%

문제

홍준이와 아이들은 2014년을 맞이하여 n개의 행성을 여행하려고 한다. 편의상 행성에 0번부터 n-1까지 번호를 매긴다. 우주선을 타고 우주 여행을 하면 사고가 발생할 수 있으므로, 사성(Sasung)과 부글(Boogle)에서 공동 연구하여 개발한 신제품 '텔레점프 텔레포트 시스템'을 통해 순간이동으로 여행을 할 계획이다. 홍준이와 아이들은 0번 행성에서 여행을 시작하고, 임의의 행성에서 여행을 끝낼 수 있다.

텔레점프를 작동시키려면 티켓을 이용해야 한다. 티켓은 총 3가지 종류가 있다. 첫 번째 티켓을 사용하면 x번째 행성에서 x+1(x+1 ≤ n-1)번째 또는 x-1(x-1 ≥ 0)번째 행성으로 이동할 수 있다. 두 번째 티켓을 사용하면 x번째 행성에서 x+2(x+2 ≤ n-1)번째 또는 x-2(x-2 ≥ 0)번째 행성으로 이동할 수 있다. 세 번째 티켓을 사용하면 x번째 행성에서 x+3(x+3 ≤ n-1)번째 또는 x-3(x-3 ≥ 0)번째 행성으로 이동할 수 있다.

홍준이와 아이들은 첫 번째 티켓을 a개, 두 번째 티켓을 b개, 세 번째 티켓을 c개 가지고 있다. 따라서, 홍준이와 아이들은 a+b+c+1=n개의 행성을 여행할 수 있다. 홍준이는 사성 회사의 프리미엄 고객이므로 각 종류의 티켓들을 적어도 3개씩은 가지고 있다.(즉, 최소 10개의 행성은 여행할 수 있으므로 n ≥ 10이다)

이제 프로그램을 작성하여, 홍준이와 아이들이 모든 행성들을 방문하려면 어떤 순서로 행성들을 여행해야할 지 알려주자.

입력

입력은 T개의 테스트 케이스(1 ≤ t ≤ 20)로 구성되어있다.

다음 T개의 각 줄에는 3개의 정수: ai, bi ,ci (3 ≤ ai, bi, ci ≤ 5000)가 주어진다. 각 테스트 케이스마다 ni는 ai+bi+ci+1과 같다.

출력

각 테스트 케이스에 대해서 한 줄씩 출력한다. 각 줄에는 방문한 행성들을 나타내는 정수 ni개를 공백으로 구분해 출력한다.

만약 해가 유일하지 않다면, 아무거나 출력해도된다. 항상 해가 존재하는 경우만 입력으로 주어진다.

예제 입력 1

2
3 3 3
3 4 3

예제 출력 1

0 3 1 2 5 4 6 9 7 8
0 3 1 2 5 4 6 9 7 8 10

힌트

첫 번째 예제의 경우, 홍준이와 아이들은 각 티켓을 종류별로 3개씩 가지고 있다. 즉, 행성은 0번부터 9번까지 총 10개가 존재한다. 홍준이와 아이들은 0번 행성에서 출발한다. 첫 번째 티켓을 사용해서 1 → 2, 5 → 4, 7 → 8, 두 번째 티켓을 사용해서 3 → 1, 4 → 6,  9 → 7, 세 번째 티켓을 사용해서 0 → 3, 2 → 5, 6 → 9로 이동할 수 있다.

W3sicHJvYmxlbV9pZCI6IjM5OTkiLCJwcm9ibGVtX2xhbmciOiIwIiwidGl0bGUiOiJcdWQxNTRcdWI4MDhcdWM4MTBcdWQ1MDQiLCJkZXNjcmlwdGlvbiI6IjxwPlx1ZDY0ZFx1YzkwMFx1Yzc3NFx1YzY0MCBcdWM1NDRcdWM3NzRcdWI0ZTRcdWM3NDAgMjAxNFx1YjE0NFx1Yzc0NCBcdWI5ZGVcdWM3NzRcdWQ1NThcdWM1ZWMgblx1YWMxY1x1Yzc1OCBcdWQ1ODlcdWMxMzFcdWM3NDQgXHVjNWVjXHVkNTg5XHVkNTU4XHViODI0XHVhY2UwIFx1ZDU1Y1x1YjJlNC4gXHVkM2I4XHVjNzU4XHVjMGMxIFx1ZDU4OVx1YzEzMVx1YzVkMCZuYnNwOzBcdWJjODhcdWJkODBcdWQxMzAgbi0xXHVhZTRjXHVjOWMwIFx1YmM4OFx1ZDYzOFx1Yjk3YyBcdWI5ZTRcdWFlMzRcdWIyZTQuJm5ic3A7XHVjNmIwXHVjOGZjXHVjMTIwXHVjNzQ0IFx1ZDBjMFx1YWNlMCBcdWM2YjBcdWM4ZmMgXHVjNWVjXHVkNTg5XHVjNzQ0IFx1ZDU1OFx1YmE3NCBcdWMwY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