#include <bits/stdc++.h>
#pragma GCC optimize("Ofast")
using namespace std;
const int inf = 1e18;
const int N = 2e5 + 22;
const long long mod = 1e9 + 7;
int n, k;
vector<int> g[N];
int c[N];
int sz[N];
vector<int> ve;
void calc(int v, int p) {
  sz[v] = c[v];
  for (auto to : g[v]) {
    if (to == p) continue;
    calc(to, v);
    sz[v] += sz[to];
  }
}
void dfs(int v, int p) {
  if (c[v]) ve.push_back(v);
  for (auto to : g[v]) {
    if (to != p) dfs(to, v);
  }
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  cin >> n >> k;
  k *= 2;
  for (int i = 0; i < n - 1; ++i) {
    int u, v;
    cin >> u >> v;
    u--, v--;
    g[u].push_back(v);
    g[v].push_back(u);
  }
  for (int i = 0; i < k; ++i) {
    int x;
    cin >> x;
    x--;
    c[x] = 1;
  }
  calc(0, 0);
  int need = k / 2;
  int v = 0;
  int p = 0;
  bool run = 1;
  while (run) {
    run = 0;
    for (auto to : g[v]) {
      if (to != p && sz[to] > need) {
        run = 1;
        p = v;
        v = to;
        break;
      }
    }
  }
  dfs(v, v);
  cout << 1 << '\n' << v + 1 << '\n';
  for (int i = 0; i < k / 2; ++i) {
    cout << ve[i] + 1 << ' ' << ve[i + k / 2] + 1 << ' ' << v + 1 << '\n';
  }
}
