#include <bits/stdc++.h>
using namespace std;
const int MAXN = 130000;
bool bitan[MAXN + 5];
int n, m, poc = MAXN;
int maxx, sol1, sol2;
vector<int> v[MAXN + 5];
bool bio[MAXN + 5];
inline pair<pair<int, int>, int> MP(int a, int b, int c) {
  return make_pair(make_pair(a, b), c);
}
pair<pair<int, int>, int> dfs(int curr, int dep) {
  bio[curr] = 1;
  int ret = 0;
  int dis = 0, tko = MAXN, nju = 0;
  if (bitan[curr]) dis = 0, tko = curr;
  for (int i = (0), _for = (v[curr].size()); i < _for; ++i) {
    int nx = v[curr][i];
    if (bio[nx]) continue;
    pair<pair<int, int>, int> pom = dfs(nx, dep + 1);
    if (pom.second == 0) continue;
    ret += pom.second;
    nju = pom.first.first - dep;
    if ((dis || bitan[curr]) && dis + nju == maxx) {
      sol1 = min(sol1, min(tko, pom.first.second));
    }
    if ((dis || bitan[curr]) && dis + nju > maxx) {
      maxx = dis + nju;
      sol1 = min(tko, pom.first.second);
    }
    if (nju == dis) {
      tko = min(tko, pom.first.second);
    }
    if (nju > dis) {
      dis = nju;
      tko = pom.first.second;
    }
  }
  if (!ret && bitan[curr]) return MP(dep, curr, 1);
  if (!ret) return MP(0, 0, 0);
  return MP(dis + dep, tko, ret + 1);
}
int main() {
  scanf("%d%d", &n, &m);
  for (int i = (0), _for = (n - 1); i < _for; ++i) {
    int a, b;
    scanf("%d%d", &a, &b);
    a--;
    b--;
    v[a].push_back(b);
    v[b].push_back(a);
  }
  for (int i = (0), _for = (m); i < _for; ++i) {
    int a;
    scanf("%d", &a);
    a--;
    poc = min(poc, a);
    bitan[a] = 1;
  }
  if (m == 1) {
    printf("%d\n%d\n", poc + 1, 0);
    return 0;
  }
  sol2 = dfs(poc, 0).second - 1;
  sol2 *= 2;
  sol2 -= maxx;
  printf("%d\n%d\n", sol1 + 1, sol2);
  return 0;
}
