#include <bits/stdc++.h>
using namespace std;
const int MX = 305;
vector<int> adj[MX];
vector<int> l, ans;
int dfs(int u, int v, vector<int>& p, int par = 0) {
  int sum = 0;
  for (int w : adj[u]) {
    if (w != par) {
      p.push_back(w);
      sum = max(sum, dfs(w, v, p, u));
      p.pop_back();
    }
  }
  if (u == v) {
    for (int i : p) ans.push_back(i);
    return p.size();
  }
  return sum;
}
int main() {
  int n, k = 0;
  cin >> n;
  for (int i = 1; i < n; i++) {
    int u, v;
    cin >> u >> v;
    adj[u].push_back(v);
    adj[v].push_back(u);
  }
  for (int i = 2; i <= n; i++)
    if (adj[i].size() == 1) k++;
  for (int i = 0; i < k; i++) {
    int u;
    cin >> u;
    l.push_back(u);
  }
  l.push_back(1);
  vector<int> vec[k + 1];
  int sum = 0;
  int u = 1;
  for (int i = 0; i <= k; i++) {
    sum += dfs(u, l[i], vec[i], u);
    u = l[i];
  }
  if (sum != 2 * n - 2)
    cout << "-1" << '\n';
  else {
    cout << '1' << ' ';
    for (int i : ans) cout << i << ' ';
  }
}
