#include <bits/stdc++.h>
using namespace std;
set<int> adj_list[100005];
int sub[100005];
int ans[100005];
int size_dfs(int node, int parent) {
  sub[node] = 1;
  for (auto neig : adj_list[node])
    if (neig != parent) sub[node] += size_dfs(neig, node);
  return sub[node];
}
int cent_bfs(int node, int parent, int siz) {
  queue<pair<int, int>> q;
  q.push(make_pair(node, parent));
  while (!q.empty()) {
    int w = q.front().first;
    int p = q.front().second;
    q.pop();
    bool cont = false;
    for (auto neig : adj_list[w]) {
      if (neig != p) {
        if (sub[neig] > siz / 2) {
          q.push(make_pair(neig, w));
          cont = true;
          break;
        }
      }
    }
    if (!cont) return w;
  }
  return node;
}
void create_tree(int start, int parent, int chr) {
  int siz = size_dfs(start, parent);
  int centroid = cent_bfs(start, parent, siz);
  ans[centroid] = chr;
  int total_neig = (int)adj_list[centroid].size();
  for (int i = 0; i < total_neig; i++) {
    int neig = *adj_list[centroid].begin();
    adj_list[centroid].erase(neig);
    adj_list[neig].erase(centroid);
    create_tree(neig, centroid, chr + 1);
  }
}
int main(int argc, const char* argv[]) {
  int n;
  scanf(" %d", &n);
  for (int i = 0; i < n - 1; i++) {
    int a, b;
    scanf(" %d%d", &a, &b);
    adj_list[a].insert(b);
    adj_list[b].insert(a);
  }
  create_tree(1, 0, 65);
  for (int i = 1; i <= n; i++) printf("%c ", (char)ans[i]);
  printf("\n");
  return 0;
}
