#include <bits/stdc++.h>
using namespace std;
int n, x, y, sub[100005], visit[100005];
vector<int> v[100005];
void subsize(int node, int ata) {
  sub[node] = 1;
  for (int i = 0; i < (int)v[node].size(); i++) {
    int x = v[node][i];
    if (x != ata && !visit[x]) {
      subsize(x, node);
      sub[node] += sub[x];
    }
  }
}
int find(int node, int val) {
  for (int i = 0; i < (int)v[node].size(); i++) {
    if (!visit[v[node][i]] && sub[v[node][i]] > val / 2 &&
        sub[v[node][i]] < sub[node]) {
      return find(v[node][i], val);
    }
  }
  return node;
}
void solve(int u, int c) {
  subsize(u, -1);
  int x = find(u, sub[u]);
  visit[x] = c;
  for (int i = 0; i < (int)v[x].size(); i++) {
    if (!visit[v[x][i]]) {
      solve(v[x][i], c + 1);
    }
  }
}
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n - 1; i++) {
    scanf("%d %d", &x, &y);
    v[x].push_back(y);
    v[y].push_back(x);
  }
  solve(1, 1);
  for (int i = 1; i <= n; i++) {
    printf("%c ", visit[i] + 64);
  }
  return 0;
}
