You are given a connected directed acyclicgraph with N vertices (2 <= N <= 20). Two players are playing the following game: First they put chip into some vertex of the graph. Then they in turns do the following: 1. Choose any edge, which goes from the vertex chip located in; 2. Move chip along this edge. Player, who cannot do his turn (because there are no outgoing edges from the current vertex) looses the game. Given starting vertex, determine what move should do first player in order to win, assuming that both players play optimally. Input data specification On the first line of the input there are three integer numbers: N, M and S, where N is number of vertices, M is number of edges and S is the 1-based number of starting vertex. Then M lines follow, each with two positive numbers A and B, describing edge going from vertex A to vertex B. Output data specification If it is impossible to win, starting from the given vertex, output a single number -1. Otherwise list all possible vertices, each on a separate line, in ascending order, going to which first player will win. Remember, that both players play optimally. Sample input 7 10 4 1 2 2 3 4 2 4 3 4 6 5 6 5 1 6 7 3 6 3 7 Sample output 2 Note Sample graph is the one which was described on the lecture. Find example of the game on the 9th slide.