A class has K students in total, and some of them dislike each other intensely. Students who dislike each other never want to run into one another anywhere outside the classroom on their way to school. Every student starts at intersection 1 and walks to intersection 2, where the classroom is. Determine whether the students can be assigned K distinct routes such that, apart from the start (1) and the destination (2), no two routes share any intersection or any road.
The input consists of several test cases.
The first line of each test case contains the number of routes to assign, K, and the number of intersections, N. The intersections are numbered from 1 to N. Among the following N lines, the i-th line lists, in increasing order, the numbers of the intersections directly connected to intersection i. Every intersection is connected to at least one other intersection.
The last line of the input is 0 0, which should not be processed.
1≤K≤100 and 2≤N≤5000. Every student starts at intersection 1, and the classroom is at intersection 2.
For each test case, first print the case number x in the format Case x: (numbering starts at 1). On the next line, print Possible if K routes satisfying the condition can be assigned, or Impossible otherwise.
After the result of each test case, print one blank line.