Problem: You are given an undirected tree, consisting of n vertices.

The vertex is called a leaf if it has exactly one vertex adjacent to it.

The distance between some pair of vertices is the number of edges in the shortest path between them.

Let's call some set of leaves beautiful if the maximum distance between any pair of leaves in it is less or equal to k.

You want to split all leaves into non-intersecting beautiful sets. What is the minimal number of sets in such a split?

Input

The first line contains two integers n and k (3 ≤ n ≤ 10^6, 1 ≤ k ≤ 10^6) — the number of vertices in the tree and the maximum distance between any pair of leaves in each beautiful set.

Each of the next n - 1 lines contains two integers v_i and u_i (1 ≤ v_i, u_i ≤ n) — the description of the i-th edge. 

It is guaranteed that the given edges form a tree.

Output

Print a single integer — the minimal number of beautiful sets the split can have. 

Examples

Input

9 3
1 2
1 3
2 4
2 5
3 6
6 7
6 8
3 9


Output

2


Input

5 3
1 2
2 3
3 4
4 5


Output

2


Input

6 1
1 2
1 3
1 4
1 5
1 6


Output

5

Note

Here is the graph for the first example:

<image>

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
const int N = 2e6 + 10;
inline int read() {
  char ch = getchar();
  int t = 1;
  int x = 0;
  for (; ch > '9' || ch < '0'; ch = getchar())
    if (ch == '-') t = -1;
  for (; ch >= '0' && ch <= '9'; ch = getchar())
    x = (x << 1) + (x << 3) + (ch - 48);
  return x * t;
}
struct edge {
  int to, next;
} a[N << 1];
int head[N];
int cnt = 0;
int K;
int n;
const int INF = 1e9;
inline void add(int x, int y) {
  a[++cnt] = (edge){y, head[x]};
  head[x] = cnt;
}
int near[N], away[N];
int du[N];
int ans = 0;
void dfs(int u, int fa) {
  near[u] = INF;
  away[u] = -INF;
  for (register int v, i = head[u]; i; i = a[i].next) {
    v = a[i].to;
    if (v == fa) continue;
    dfs(v, u);
    near[u] = min(near[v] + 1, near[u]);
    if (near[v] + away[v] > K) away[u] = max(away[u], away[v] + 1);
  }
  if (fa) {
    if (away[u] >= K)
      ++ans, away[u] = -INF, near[u] = 0;
    else if (du[u] == 1)
      away[u] = 0;
  } else {
    if (du[u] == 1) away[u] = max(away[u], 0);
    if (near[u] + away[u] > K) ++ans;
  }
  return;
}
int main() {
  n = read();
  K = read();
  register int u, v;
  for (register int i = n - 1; i; --i) {
    u = read();
    v = read();
    ++n;
    add(u, n);
    add(n, u);
    add(v, n);
    add(n, v);
    ++du[u];
    ++du[v];
  }
  dfs(1, 0);
  printf("%d\n", ans);
}