#include <bits/stdc++.h>
using namespace std;
const int N = 123460;
vector<int> adj[N], drkht[N];
bitset<N> B, mrk;
int n, m, mx = -1, mn = 1e9, tmp, cnt, a, b;
bool DFS(int u, int p) {
  B[u] = 1;
  bool b = mrk[u];
  for (auto x : adj[u])
    if (!B[x]) b |= DFS(x, u);
  if (b && p != -1) {
    cnt += 2;
    drkht[p].push_back(u);
  }
  return (b);
}
pair<int, int> DFS2(int u, int p) {
  pair<int, int> asl, tmp;
  asl.first = -1;
  int ttmp1, ttmp2;
  priority_queue<pair<int, int>, vector<pair<int, int> >,
                 greater<pair<int, int> > >
      pq;
  for (auto x : drkht[u])
    if (x != p) {
      tmp = DFS2(x, u);
      if (tmp.first > asl.first)
        asl = tmp;
      else if (tmp.first == asl.first)
        asl.second = min(asl.second, tmp.second);
      pq.push(make_pair(tmp.first + 1, -tmp.second));
      if ((int)pq.size() == 3) pq.pop();
    }
  asl.first++;
  if (pq.empty())
    return (make_pair(0, u));
  else if ((int)pq.size() == 1) {
    if (asl.first > mx) {
      mx = asl.first, mn = min(u, asl.second);
    } else if (asl.first == mx)
      mn = min(mn, min(u, asl.second));
    return (asl);
  }
  ttmp1 = pq.top().first, ttmp2 = -pq.top().second;
  pq.pop();
  if (mx < ttmp1 + pq.top().first) {
    mx = ttmp1 + pq.top().first;
    mn = min(ttmp2, -pq.top().second);
  } else if (mx == pq.top().first + ttmp1)
    mn = min(mn, min(ttmp2, -pq.top().second));
  return (asl);
}
int main() {
  scanf("%d %d", &n, &m);
  for (int i = 1; i < n; i++) {
    scanf("%d %d", &a, &b);
    adj[a].push_back(b);
    adj[b].push_back(a);
  }
  for (int i = 0; i < m; i++) {
    scanf("%d", &a);
    mrk[a] = 1;
  }
  DFS(a, -1);
  pair<int, int> ptmp = DFS2(a, -1);
  if (ptmp.first > mx)
    mx = ptmp.first, mn = ptmp.second;
  else if (ptmp.first == mx)
    mn = min(mn, ptmp.second);
  printf("%d\n%d", mn, cnt - mx);
}
