Note: The main parts of the statements of the problems "Game Sort: Part 1" and "Game Sort: Part 2" are identical, except for the last paragraph. The problems can otherwise be solved independently.
Amir and Badari are playing a sorting game. The game starts with a string and an integer being chosen by an impartial judge. Then, Amir has to split into exactly contiguous non-empty parts (substrings). For example, if was the chosen string and , Amir could split it up as or as , but not as , , , nor as .
Then, Badari must rearrange the letters within each part to make the list of parts be sorted in non-decreasing lexicographical order. If she can, then she wins. Otherwise, Amir wins.
Given the initial string and number of parts, can you help Amir win the game by choosing his parts in a way Badari cannot win herself? If not, say that it is not possible.
输入格式
The first line of the input gives the number of test cases, . lines follow, each describing a single test case containing an integer and a string , the number of parts and string to be partitioned, respectively.
输出格式
For each test case, output one line containing Case #x: y, where is the test case number (starting from 1) and is either POSSIBLE if Amir can win the game, or IMPOSSIBLE if he cannot. If he can win the game, output a second line containing where is the -th part of the winning partition you found for Amir. If there are multiple solutions, you may output any one of them.