Mr. Kuo is an adventurer. One day, he finds a special "tree".
The tree consists of N vertices.
There are exactly one simple path between any two vertices.
Mr. Kuo wants to do the following operation K times to this tree:
(A leaf of a tree is a vertex that is connected to at most one vertex.)
Mr. Kuo is wondering how many vertices will remain after he performs the operations K times.
Take the sample test as the example:
The picture below is the tree of the test case 4 in the sample test.

The picture below is the tree after Mr. Kuo performs the operation once.

The first line contains one integer T — the number of test cases. Description of the test cases follows.
The first line of each test cases contains two integer N K — the number of vertices in the tree and the number of operations Mr. Kuo performs.
Each of the next N - 1 lines contains two integers ui and vi — there is an edge between ui and vi.
For each test:
1 ≤ ui, vi ≤ N
0 ≤ K ≤ N for all test.
For each test case print an integer — the number of verticees remain in the tree.