Hasan is lazy. He likes to stay asleep in the morning. But the dorm's supervisor always wakes him up. He will try to run from her.
The dorm consists of $$$N$$$ rooms. There are $$$M$$$ portals between these rooms. To catch Hasan, the supervisor will stand at one of these portals. The supervisor can catch Hasan only if she stands in a portal between two rooms such that this portal is the only way to get between these two rooms.
Hasan can add one portal between any two rooms in the dorm; if he added it optimally, what is the minimum number of portals that the supervisor can use to catch him.
First line of the input will be $$$T$$$, the number of test cases.
Each test case starts with a line of two numbers, $$$N$$$, $$$M$$$ ($$$ 1 \le N, M \le 10^5 $$$)the number of rooms and portals.
Next $$$M$$$ lines contain two integers, $$$u$$$ and $$$v$$$ the rooms of the $$$i_{th}$$$ portal($$$ 1 \le u, v \le N $$$).
For each test case, print one line, the minimum number of portals that the supervisor can use to catch him.
2 3 2 1 2 2 3 9 11 3 2 3 8 2 8 1 2 1 5 1 4 5 9 7 5 4 5 6 4 4 7
0 1