#include <bits/stdc++.h>
using namespace std;
const int INF = 0x3f3f3f3f;
const int maxn = 350;
struct node {
  int v, id;
  node *next;
} ed[maxn << 4], *head[maxn], *q[maxn];
struct qnode {
  int u, v, ans;
} qu[maxn];
int vis[maxn], fa[maxn], le[maxn], ans[maxn << 2], ptr, cnt;
int up[maxn], ve[maxn], flag;
char buf[1500];
void adde(node *h[], int u, int v, int id) {
  ed[cnt].v = v;
  ed[cnt].id = id;
  ed[cnt].next = h[u];
  h[u] = &ed[cnt++];
}
int getfa(int u) {
  if (fa[u] == u) return u;
  return fa[u] = getfa(fa[u]);
}
void tarjan(int u) {
  fa[u] = u;
  up[u] = u;
  vis[u] = 1;
  for (node *p = q[u]; p != NULL; p = p->next)
    if (vis[p->v]) qu[p->id].ans = getfa(p->v);
  for (node *p = head[u]; p != NULL; p = p->next) {
    if (!vis[p->v]) {
      tarjan(p->v);
      fa[p->v] = u;
      up[p->v] = u;
    }
  }
}
void getre(int u, int fa) {
  if (u == fa) return;
  if (ve[u] >= 2) flag = 1;
  ve[u]++;
  getre(up[u], fa);
  ans[ptr++] = u;
}
int main() {
  int n, u, v, i, ct;
  stringstream ss;
  while (~scanf("%d", &n)) {
    cnt = ct = ptr = 0;
    memset(head, 0, sizeof head);
    memset(q, 0, sizeof q);
    memset(vis, 0, sizeof vis);
    memset(ve, 0, sizeof ve);
    for (i = 1; i < n; i++) {
      scanf("%d%d", &u, &v);
      adde(head, u, v, i);
      adde(head, v, u, i);
    }
    getchar();
    gets(buf);
    ss.clear();
    ss.str(buf);
    while (ss >> le[ct]) ct++;
    le[ct++] = 1;
    for (i = 1; i < ct; i++) {
      qu[i].u = le[i - 1];
      qu[i].v = le[i];
      adde(q, le[i - 1], le[i], i);
      adde(q, le[i], le[i - 1], i);
    }
    tarjan(1);
    flag = 0;
    ans[ptr++] = 1;
    getre(le[0], 1);
    for (i = 1; i < ct; i++) {
      if (flag) break;
      u = qu[i].u;
      v = qu[i].v;
      while (u != qu[i].ans) {
        ans[ptr++] = up[u];
        if (ve[u] >= 2) flag = 1;
        ve[u]++;
        u = up[u];
      }
      getre(v, qu[i].ans);
    }
    if (flag)
      printf("-1\n");
    else {
      printf("%d", ans[0]);
      for (i = 1; i < ptr; i++) printf(" %d", ans[i]);
      printf("\n");
    }
  }
  return 0;
}
