#include <bits/stdc++.h>
using namespace std;
void Freopen() {
  freopen(
      "title"
      ".in",
      "r", stdin);
  freopen(
      "title"
      ".out",
      "w", stdout);
}
int read() {
  int g = 0, f = 1;
  char ch = getchar();
  while (ch < '0' || '9' < ch) {
    if (ch == '-') f = -1;
    ch = getchar();
  }
  while ('0' <= ch && ch <= '9') {
    g = g * 10 + ch - '0';
    ch = getchar();
  }
  return g * f;
}
const int N = 2e5 + 5;
const int INF = 1e9;
int size[N], maxn, rt, vis[N], du[N], n, flag, prt[N], dep[N], imp, mdep,
    dis[N], last[N];
vector<int> G[N], nG[N];
void find_rt(int x, int fa, int tag) {
  size[x] = 1;
  int mx = 0;
  for (auto y : G[x])
    if (y ^ fa) {
      find_rt(y, x, tag);
      size[x] += size[y];
      mx = max(size[y], mx);
    }
  mx = max(n - size[x], mx);
  if (mx < maxn && x != tag) rt = x, maxn = mx;
}
void dfs(int x, int fa) {
  prt[x] = fa;
  dep[x] = dep[fa] + 1;
  mdep = max(mdep, dep[x]);
  last[x] = dep[x];
  if (x == rt && du[x] == 3) imp = x;
  if (du[x] == 4) imp = x;
  if (x != rt && du[x] == 2) imp = x;
  for (auto y : G[x])
    if (y ^ fa) dfs(y, x), last[x] = max(last[x], last[y]);
}
void redfs(int x, int fa) {
  int son = 0;
  dis[x] = dis[fa] + 1;
  for (auto y : nG[x])
    if (y ^ fa) redfs(y, x), son++;
  if (dis[x] < mdep && son != 2) flag = 0;
  if (dis[x] == mdep && son != 0) flag = 0;
}
void check(int rt) {
  imp = mdep = 0;
  dfs(rt, 0);
  if (!imp) return void();
  for (int i = (1); i <= (n + 1); i++) nG[i].clear();
  for (int i = (1); i <= (n); i++)
    if (prt[i] != imp && prt[i]) nG[prt[i]].push_back(i);
  for (int i = (1); i <= (n); i++)
    if (prt[i] == imp) {
      if (last[i] != mdep)
        nG[n + 1].push_back(i);
      else
        nG[imp].push_back(i);
    }
  nG[imp].push_back(n + 1);
  flag = 1;
  redfs(rt, 0);
  if (flag) vis[imp] = 1;
}
signed main() {
  n = read();
  if (n == 2) return cout << 2 << '\n' << 1 << ' ' << 2, signed();
  n = (1 << n) - 2;
  for (int i = (1); i <= (n - 1); i++) {
    int x = read(), y = read();
    G[x].push_back(y), G[y].push_back(x);
    du[x]++, du[y]++;
  }
  maxn = INF;
  find_rt(1, 0, 0);
  check(rt);
  maxn = INF;
  find_rt(1, 0, rt);
  check(rt);
  int ans = 0;
  for (int i = (1); i <= (n); i++) ans += vis[i];
  cout << ans << '\n';
  for (int i = (1); i <= (n); i++)
    if (vis[i]) cout << i << ' ';
  return signed();
}
