Problem: Recently, Berland faces federalization requests more and more often. The proponents propose to divide the country into separate states. Moreover, they demand that there is a state which includes exactly k towns.

Currently, Berland has n towns, some pairs of them are connected by bilateral roads. Berland has only n - 1 roads. You can reach any city from the capital, that is, the road network forms a tree.

The Ministry of Roads fears that after the reform those roads that will connect the towns of different states will bring a lot of trouble.

Your task is to come up with a plan to divide the country into states such that:

  * each state is connected, i.e. for each state it is possible to get from any town to any other using its roads (that is, the roads that connect the state towns), 
  * there is a state that consisted of exactly k cities, 
  * the number of roads that connect different states is minimum. 

Input

The first line contains integers n, k (1 ≤ k ≤ n ≤ 400). Then follow n - 1 lines, each of them describes a road in Berland. The roads are given as pairs of integers xi, yi (1 ≤ xi, yi ≤ n; xi ≠ yi) — the numbers of towns connected by the road. Assume that the towns are numbered from 1 to n.

Output

The the first line print the required minimum number of "problem" roads t. Then print a sequence of t integers — their indices in the found division. The roads are numbered starting from 1 in the order they follow in the input. If there are multiple possible solutions, print any of them.

If the solution shows that there are no "problem" roads at all, print a single integer 0 and either leave the second line empty or do not print it at all.

Examples

Input

5 2
1 2
2 3
3 4
4 5


Output

1
2


Input

5 3
1 2
1 3
1 4
1 5


Output

2
3 4


Input

1 1


Output

0

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
int n, k;
vector<vector<int> > adjl;
int dan[500], niche[500], par[500];
int order[500];
int dp[500][3][500];
int indx[500][500];
int func(int u, bool is_in, int k_ase) {
  if (dp[u][is_in][k_ase] != -1) {
    return dp[u][is_in][k_ase];
  }
  if (k_ase == 0) {
    int ret = 0;
    if (par[u] != -1) {
      if (par[u] != 1) {
        ret += (adjl[par[u]].size() - 1) - order[u];
      } else {
        ret += (adjl[par[u]].size()) - order[u];
      }
    }
    return dp[u][is_in][k_ase] = ret;
  }
  if ((niche[u] == -1) && (dan[u] == -1) && (k_ase > 1)) {
    return dp[u][is_in][k_ase] = 100000000;
  }
  int sz = adjl[u].size();
  int ans = 100000000;
  if (is_in == 0) {
    for (int i = 0; i <= sz - 1; i++) {
      int v = adjl[u][i];
      if (v == par[u]) {
        continue;
      }
      ans = min(ans, func(v, is_in, k_ase));
    }
    if (niche[u] != -1) {
      int cc = 0;
      if (par[u] != -1) {
        cc = 1;
      }
      ans = min(ans, cc + func(niche[u], 1, k_ase - 1));
    } else if (k_ase == 1) {
      int cc = 0;
      if (par[u] != -1) {
        cc = 1;
      }
      ans = min(ans, cc);
    }
  } else {
    if (dan[u] != -1) {
      ans = min(ans, 1 + func(dan[u], is_in, k_ase));
    }
    int tmp_k_ase = k_ase - 1;
    if ((niche[u] != -1) && (dan[u] != -1)) {
      for (int i = 0; i <= tmp_k_ase; i++) {
        ans = min(
            ans, func(niche[u], is_in, i) + func(dan[u], is_in, tmp_k_ase - i));
      }
    } else if ((niche[u] != -1)) {
      ans = min(ans, func(niche[u], is_in, k_ase - 1));
    } else if ((dan[u] != -1)) {
      ans = min(ans, func(dan[u], is_in, k_ase - 1));
    } else if (k_ase == 1) {
      ans = min(ans, 0);
    }
  }
  return dp[u][is_in][k_ase] = ans;
}
void bt(int u, bool is_in, int k_ase) {
  if (k_ase == 0) {
    int ret = 0;
    if (par[u] != -1) {
      int si = par[u];
      for (int i = order[u]; i <= (int)(adjl[si].size() - 1); i++) {
        int v = adjl[si][i];
        if ((i == order[u]) && (v != u)) {
          continue;
        }
        if (v == par[si]) {
          continue;
        }
        cout << indx[si][v] << " ";
      }
    }
    return;
  }
  if ((niche[u] == -1) && (dan[u] == -1) && (k_ase > 1)) {
    return;
  }
  int sz = adjl[u].size();
  if (is_in == 0) {
    for (int i = 0; i <= sz - 1; i++) {
      int v = adjl[u][i];
      if (v == par[u]) {
        continue;
      }
      if (dp[u][is_in][k_ase] == dp[v][is_in][k_ase]) {
        bt(v, is_in, k_ase);
        return;
      }
    }
    if (niche[u] != -1) {
      int cc = 0;
      if (par[u] != -1) {
        cc = 1;
      }
      if (dp[u][is_in][k_ase] == cc + dp[niche[u]][1][k_ase - 1]) {
        if (cc) {
          cout << indx[u][par[u]] << " ";
        }
        bt(niche[u], 1, k_ase - 1);
        return;
      }
    } else if (k_ase == 1) {
      int cc = 0;
      if (par[u] != -1) {
        cc = 1;
      }
      if (dp[u][is_in][k_ase] == cc) {
        if (cc) {
          cout << indx[u][par[u]] << " ";
        }
        return;
      }
    }
  } else {
    if (dan[u] != -1) {
      if (dp[u][is_in][k_ase] == (1 + dp[dan[u]][is_in][k_ase])) {
        cout << indx[u][par[u]] << " ";
        bt(dan[u], is_in, k_ase);
        return;
      }
    }
    int tmp_k_ase = k_ase - 1;
    if ((niche[u] != -1) && (dan[u] != -1)) {
      for (int i = 0; i <= tmp_k_ase; i++) {
        if (dp[u][is_in][k_ase] ==
            (dp[niche[u]][is_in][i] + dp[dan[u]][is_in][tmp_k_ase - i])) {
          bt(niche[u], is_in, i);
          bt(dan[u], is_in, tmp_k_ase - i);
          return;
        }
      }
    } else if ((niche[u] != -1)) {
      if (dp[u][is_in][k_ase] == dp[niche[u]][is_in][k_ase - 1]) {
        bt(niche[u], is_in, k_ase - 1);
        return;
      }
    } else if ((dan[u] != -1)) {
      if (dp[u][is_in][k_ase] == dp[dan[u]][is_in][k_ase - 1]) {
        bt(dan[u], is_in, k_ase - 1);
        return;
      }
    } else if (k_ase == 1) {
      return;
    }
  }
}
void bfs(int u, int pp) {
  par[u] = pp;
  int sz = adjl[u].size();
  vector<int> nodes;
  for (int i = 0; i <= sz - 1; i++) {
    int v = adjl[u][i];
    if (v == pp) {
      continue;
    }
    nodes.push_back(v);
    bfs(v, u);
  }
  if (nodes.size()) {
    niche[u] = nodes[0];
    order[nodes[0]] = 0;
  }
  for (int i = 1; i <= (int)(nodes.size() - 1); i++) {
    dan[nodes[i - 1]] = nodes[i];
    order[nodes[i]] = i;
  }
}
int main() {
  std::ios_base::sync_with_stdio(false);
  ;
  cin >> n >> k;
  adjl.resize(n + 1, vector<int>(0));
  for (int i = 1; i <= n - 1; i++) {
    int u, v;
    cin >> u >> v;
    adjl[u].push_back(v);
    adjl[v].push_back(u);
    indx[u][v] = i;
    indx[v][u] = i;
  }
  memset((dan), -1, sizeof(dan));
  memset((niche), -1, sizeof(niche));
  bfs(1, -1);
  memset((dp), -1, sizeof(dp));
  cout << func(1, 0, k) << "\n";
  bt(1, 0, k);
  return 0;
}