#include <bits/stdc++.h>
using ll = long long;
using ull = unsigned long long;
using ld = long double;
using namespace std;
const double PI = 3.141592654;
const int N = 1e6 + 1;
ll MOD = 1e9 + 7;
vector<vector<int>> gp;
vector<bool> vis;
vector<int> qr;
vector<int> ans;
bool dfs(int u, int v) {
  vis[u] = 1;
  if (u == v) {
    return 1;
  }
  for (auto& a : gp[u]) {
    if (!vis[a] && dfs(a, v)) {
      ans.push_back(a);
      return 1;
    }
  }
  return 0;
}
void solve() {
  int n;
  scanf("%d", &n);
  vis.resize(n), gp.resize(n);
  int cnt = n;
  for (int i = 0; i < n - 1; i++) {
    int u, v;
    scanf("%d%d", &u, &v);
    gp[--u].push_back(--v);
    gp[v].push_back(u);
    if (gp[u].size() == 2) cnt--;
    if (gp[v].size() == 2) cnt--;
  }
  cnt -= gp[0].size() < 2;
  qr.resize(cnt + 2);
  qr[0] = 0, qr.back() = 0;
  for (int i = 1; i <= cnt; i++) {
    scanf("%d", &qr[i]);
    qr[i]--;
  }
  for (int i = 1; i < cnt + 2; i++) {
    vis.assign(n, false);
    dfs(qr[i], qr[i - 1]);
  }
  ans.push_back(0);
  if (ans.size() == 2 * n - 1) {
    for (auto& u : ans) printf("%d ", u + 1);
    printf("\n");
    return;
  }
  printf("-1\n");
}
int main() {
  solve();
  return 0;
}
