#include <bits/stdc++.h>
using namespace std;
const int N = 200005;
vector<int> G[N];
int n, k, root;
bool used[N];
int f[N];
vector<int> vertices;
void dfs(int u, int pre) {
  f[u] = used[u];
  for (auto v : G[u]) {
    if (v == pre) continue;
    dfs(v, u);
    f[u] += f[v];
  }
}
int findRoot(int u, int pre) {
  for (auto v : G[u]) {
    if (v == pre) continue;
    if (f[v] > k) return findRoot(v, u);
  }
  return u;
}
void solve(int u, int pre) {
  for (auto v : G[u]) {
    if (v == pre) continue;
    solve(v, u);
  }
  if (used[u]) vertices.push_back(u);
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cin >> n >> k;
  for (int(i) = (2); (i) <= (n); ++(i)) {
    int u, v;
    cin >> u >> v;
    G[u].push_back(v);
    G[v].push_back(u);
  }
  for (int(i) = (1); (i) <= (2 * k); ++(i)) {
    int x;
    cin >> x;
    used[x] = 1;
  }
  dfs(1, 0);
  root = findRoot(1, 0);
  solve(root, 0);
  cout << 1 << '\n' << root << '\n';
  for (int i = 0; i < k; ++i)
    cout << vertices[i] << ' ' << vertices[i + k] << ' ' << root << '\n';
}
