#include <bits/stdc++.h>
using namespace std;
class CenterTreeAL {
 public:
  vector<int> dpth;
  vector<int> par;
  vector<int> assignval;
  vector<int> avail;
  vector<vector<int> > cdrn;
  int rix;
  CenterTreeAL(int n) {
    dpth.resize(n);
    par.resize(n, -1);
    assignval.resize(n, -1);
    cdrn.resize(n);
    avail.resize(26);
    for (int i = 0; i < 26; i++) avail[i] = 0;
    avail[0] = 1;
  }
  ~CenterTreeAL() {
    dpth.clear();
    par.clear();
    cdrn.clear();
    assignval.clear();
  }
  void dfs(int inx) {
    for (int i = 25; i >= 0 && assignval[inx] == -1; i--)
      if (avail[i]) {
        assignval[inx] = i;
        avail[i] = 0;
      }
    for (int i = 0; i < cdrn[inx].size(); i++)
      if (assignval[cdrn[inx][i]] == -1) {
        for (int j = assignval[inx] + 1; j < 26; j++) avail[j] = 1;
        dfs(cdrn[inx][i]);
      }
  }
};
class TreeAL {
 public:
  int n;
  vector<vector<int> > ed;
  vector<int> nc;
  TreeAL() { n = 0; }
  TreeAL(int tn) {
    n = tn;
    ed.resize(n);
    nc.resize(n);
    for (int i = 0; i < n; i++) nc[i] = 0;
  }
  ~TreeAL() {
    ed.clear();
    nc.clear();
  }
  void addEdge(int a, int b) {
    ed[a].push_back(b);
    ed[b].push_back(a);
    nc[a]++;
    nc[b]++;
  }
  void centerTree(CenterTreeAL *g) {
    int *q;
    int qb = 0, qe = 0, ti, ni;
    q = new int[2 * n];
    for (int i = 0; i < n; i++)
      if (nc[i] == 1) {
        q[qe++] = i;
        g->dpth[i] = 1;
      }
    while (qb < qe) {
      ti = q[qb++];
      nc[ti]--;
      for (int i = 0; i < ed[ti].size(); i++)
        if (g->par[ed[ti][i]] == -1) {
          ni = ed[ti][i];
          g->par[ti] = ni;
          g->cdrn[ni].push_back(ti);
          g->dpth[ni] = max(g->dpth[ni], g->dpth[ti] + 1);
          nc[ni]--;
          if (nc[ni] == 0) g->rix = ni;
          if (nc[ni] == 1) {
            q[qe++] = ni;
          }
        }
    }
  }
};
void doit() {
  int n, a, b;
  char tc;
  TreeAL *tg;
  CenterTreeAL *cg;
  cin >> n;
  tg = new TreeAL(n);
  cg = new CenterTreeAL(n);
  for (int i = 0; i < n - 1; i++) {
    cin >> a >> b;
    tg->addEdge(a - 1, b - 1);
  }
  tg->centerTree(cg);
  cg->dfs(cg->rix);
  for (int i = 0; i < n; i++) {
    if (i) cout << " ";
    cout << (char)('A' + cg->assignval[i]);
  }
  cout << endl;
  return;
}
int main() {
  doit();
  return 0;
}
