An Array and Several More Arrays
There are arrays of integers , where the array with index contains elements. Let .
You need to find integers such that the numbers are pairwise distinct and satisfy .
Input
The first line contains two integers and (, ) – the total number of elements in the arrays and the number of arrays, respectively.
The next lines contain the arrays. The -th line contains an integer () and integers () – the length and elements of the -th array, respectively.
It is guaranteed that .
Output
If the required values of do not exist, output a single line "No".
Otherwise, output "Yes" on the first line.
On the second line, output integers – the values that need to be added to the elements of the arrays to form a total of distinct integers from to .
If there are multiple correct answers, any one of them may be output.
Examples
Note
In the first example, satisfies the condition, since after adding the corresponding values, the arrays , , , , are formed.
In the second example, satisfies the condition, since after adding the corresponding values, the arrays , , , are formed.
In the third example, satisfies the condition, since after adding the corresponding values, the arrays and are formed.
Scoring
( points): ;
( points): for , ;
( points): ;
( points): ;
( points): for , ;
( points): for ;
( points): ;
( points): without additional constraints.