#include <bits/stdc++.h>
using namespace std;
int head[100005], tot, n, rt;
int mx[100005], son[100005], mk[100005];
int flag, sum, sz[100005];
char ans[100005];
struct name {
  int id, nx;
} to[100005 << 1];
void add(int x, int y) {
  to[++tot] = (name){y, head[x]};
  head[x] = tot;
}
void get_rt(int x, int f) {
  sz[x] = 1;
  mx[x] = 0;
  for (int i = head[x]; i; i = to[i].nx) {
    int y = to[i].id;
    if (y == f || mk[y]) continue;
    get_rt(y, x);
    sz[x] += sz[y];
    if (mx[x] < sz[y]) mx[x] = sz[y];
  }
  mx[x] = max(mx[x], sum - sz[x]);
  if (mx[rt] > mx[x]) rt = x;
}
void dfs(int x, char nw) {
  if (nw > 'Z') {
    flag = 1;
    return;
  }
  mk[x] = 1;
  ans[x] = nw;
  for (int i = head[x]; i; i = to[i].nx) {
    int y = to[i].id;
    if (mk[y]) continue;
    rt = 0, sum = sz[y];
    get_rt(y, x);
    dfs(rt, nw + 1);
  }
}
int main() {
  scanf("%d", &n);
  for (int i = (1), _en = (n - 1); i <= _en; i++) {
    int x, y;
    scanf("%d%d", &x, &y);
    add(x, y);
    add(y, x);
  }
  sum = n;
  mx[0] = 1e9, rt = 0;
  get_rt(1, 0);
  dfs(rt, 'A');
  if (flag)
    puts("Impossible");
  else
    for (int i = (1), _en = (n); i <= _en; i++) printf("%c ", ans[i]);
  return 0;
}
