#include <bits/stdc++.h>
using namespace std;
long long mod = 1e9 + 7, n, m, a[500005];
long long lim, tim = 1;
vector<long long> v1[500005];
long long parent[500005], sub[500005], ans[500005];
long long up[500005][30], in[500005], out[500005];
long long level[500005], mark[500005], depth[500005], tot;
long long flag;
vector<long long> g[500005];
long long root;
long long res;
void dfs(long long u, long long par) {
  sub[u] = 1;
  tot++;
  for (auto it : v1[u])
    if (it != par && !mark[it]) {
      dfs(it, u);
      sub[u] += sub[it];
    }
}
void dfs2(long long u, long long par) {
  depth[u] = depth[par] + 1;
  if (depth[u] > 25) flag = 1;
  for (auto it : g[u])
    if (it != par) dfs2(it, u);
}
long long centroid(long long u, long long par) {
  for (auto it : v1[u])
    if (it != par && sub[it] > tot / 2 && !mark[it]) return centroid(it, u);
  return u;
}
void decompose(long long u, long long par) {
  tot = 0;
  dfs(u, u);
  long long cen = centroid(u, u);
  if (par == -1) par = cen;
  parent[cen] = par;
  mark[cen] = 1;
  g[parent[cen]].push_back(cen);
  g[cen].push_back(parent[cen]);
  if (u == 1 && !res) {
    root = cen;
    res = 1;
  }
  for (auto it : v1[cen])
    if (!mark[it]) decompose(it, cen);
}
int main() {
  scanf("%lld", &n);
  for (long long i = 1; i < n; i++) {
    long long u, v;
    scanf("%lld %lld", &u, &v);
    v1[u].push_back(v);
    v1[v].push_back(u);
  }
  decompose(1, -1);
  dfs2(root, root);
  if (!flag)
    for (long long i = 1; i < n + 1; i++) cout << (char)(depth[i] + 64) << " ";
  else
    cout << "Impossible";
}
