#include <bits/stdc++.h>
using namespace std;
int stree[300007];
int removed[300007];
int tot;
vector<int> adj[300007];
void dfs(int u, int papa) {
  tot++;
  stree[u] = 1;
  for (auto v : adj[u]) {
    if (v == papa || removed[v]) continue;
    dfs(v, u);
    stree[u] += stree[v];
  }
}
int find_center(int u, int papa) {
  for (auto v : adj[u]) {
    if (v == papa || removed[v]) continue;
    if (stree[v] > tot / 2) return find_center(v, u);
  }
  return u;
}
int flag[300007];
int ret;
void decompose(int u, int id) {
  if (id > 25) {
    ret = 1;
    return;
  }
  tot = 0;
  dfs(u, -1);
  int center = find_center(u, -1);
  flag[center] = id;
  removed[center] = 1;
  for (auto v : adj[center]) {
    if (removed[v]) continue;
    decompose(v, id + 1);
  }
}
int main() {
  int n;
  scanf("%d", &(n));
  ;
  for (int i = 1; i <= n - 1; i++) {
    int x, y;
    scanf("%d%d", &(x), &(y));
    adj[x].push_back(y);
    adj[y].push_back(x);
  }
  decompose(1, 0);
  if (ret)
    puts("Impossible");
  else {
    for (int i = 1; i <= n; i++) {
      printf("%c%c", flag[i] + 'A', " \n"[i == n]);
    }
  }
  return 0;
}
