You need to construct an array $$$a_1, a_2, \dots, a_n$$$ $$$\left(0 \leq a_i \lt 2^{30}\right)$$$ that satisfies $$$m$$$ given constraints. Each constraint is one of two types —
The first line contains a single integer $$$t$$$ ($$$1 \le t \le 10^4$$$) — the number of test cases. The description of the test cases follows.
The first line of each test case contains two integers $$$n$$$ and $$$m$$$ ($$$1 \le n \le 10^5$$$; $$$1 \le m \le 10^5$$$) — the length of the required array and the number of constraints.
The following $$$m$$$ lines each contain the description of a constraint —
It is guaranteed that the sum of $$$n$$$ over all test cases doesn't exceed $$$10^5$$$, and the sum of $$$m$$$ doesn't exceed $$$10^5$$$.
For each test case, if it is impossible to construct such an array, print "No".
Otherwise, print "Yes" in the first line. In the second line print $$$n$$$ integers corresponding to the constructed array $$$a$$$ $$$\left(0 \leq a_i \lt 2^{30}\right)$$$ .
You can output the answer in any case (upper or lower). For example, the strings "yEs", "yes", "Yes", and "YES" will be recognized as positive responses.
If there are multiple solutions, print any.
23 41 1 02 1 2 32 2 3 12 3 1 23 41 1 02 1 2 42 2 3 12 3 1 2
YES 1 2 3 NO
| Name |
|---|


