Paintball

No attempts yetTime limit1sMemory limit256 MB

Problem

Marek and his classmates finished their university studies and celebrated with a game of paintball. After an hour something odd happened: every player had exactly one bullet left. Marek got curious and wanted to know whether every player can be hit exactly once, assuming nobody moves.

The situation at the moment when each player has one bullet is given as a list of pairs of players who can see each other. If a player can see another player, he can fire at him. Choose a target for every player so that every player is hit exactly once.

In other words, player ii picks one player he can see as his target, and every player is picked as a target exactly once.

Input

The first line contains two space separated integers NN and MM (2N10002 \le N \le 1000, 0M50000 \le M \le 5000), where NN is the number of players and MM is the number of pairs who can see each other. Players are numbered 11 through NN.

Each of the next MM lines contains two space separated integers AA and BB (1A<BN1 \le A < B \le N), meaning that players AA and BB can see each other. No pair is given more than once.

Output

If no assignment of targets hits every player exactly once, print Impossible on the first line.

Otherwise print NN lines. The ii-th line holds the number of the target of player ii. If several assignments work, print the one whose sequence (target of player 11, target of player 22, ..., target of player NN) is lexicographically smallest.