Mafia game
Phineas and Ferb decide to hold a Mafia championship in Denville.
The game has two roles - civilians and the mafia (there may be several of those). Roles are assigned to players at the very beginning of the game, after which each player with the role of a civilian knows only his role, but does not know the role of other players, while each player with the role of the mafia knows the roles of all other players.
Then several rounds (nights) are played: every night some pairs of players meet each other. And at the end of the night, one victim is announced, who was killed by the mafia that night. Every night, the mafia kills exactly one civilian, and exactly one of the mafia does it. In order for a mafia representative to kill a civilian, a meeting had to take place between them.
Candace has been watching the game so she knows the number of players and the number and description of all nights.
Help her find the minimum possible number of mafia representatives in the game, in which the game could follow the scenario known to her in order to tell her mother about the dangerous activities of Phineas and Ferb.
Input
The first line contains two integers k and m (2 ≤ k ≤ 200, 1 ≤ m ≤ * 200*, 1 ≤ k - m ≤ 15) - the number of players and number of nights in the game.
Next comes m blocks describing the nights. The description of the i-th night starts with t blocks - the description of alive players (t is the number of players alive at the start of the i-th night). Each block consists of two lines:
The first line contains two integers n and c (1 ≤ n ≤ k, 0 ≤ c ≤ t - 1) - the number of player and the number of his meetings that night.
The second line contains c positive integers - the numbers of the players that player number n has met.
It is guaranteed that all meetings were bilateral. That is, if player number a is in the list of meetings with player number b, then player b is also in the list with player a.
The last line of the description of the night contains the integer v - the number of the player who was killed that night. It is guaranteed that the input data describes a correct game.
Output
Print a single integer - the minimum number of players that must play the mafia game in order for the described game can take place.