#include <bits/stdc++.h>
using namespace std;
int n;
vector<int> g[100010], rankofnode(100010), used(100010), weight(100010);
void dfs(int x, int p) {
  weight[x] = 1;
  for (int i : g[x]) {
    if (!used[i] && i != p) {
      dfs(i, x);
      weight[x] += weight[i];
    }
  }
}
int find(int x, int p, int w) {
  for (int i : g[x]) {
    if (i != p && used[i] == 0) {
      if (weight[i] >= w) return find(i, x, w);
    }
  }
  return x;
}
void solve(int x, int depth) {
  dfs(x, 0);
  int cur = find(x, 0, weight[x] >> 1);
  rankofnode[cur] = depth;
  used[cur] = 1;
  for (int i : g[cur]) {
    if (!used[i]) solve(i, depth + 1);
  }
}
int main() {
  ios_base::sync_with_stdio(false), cin.tie(NULL), cout.tie(NULL);
  int x, y;
  cin >> n;
  for (int i = 1; i < n; ++i) {
    cin >> x >> y;
    g[x].push_back(y);
    g[y].push_back(x);
  }
  solve(1, 0);
  for (int i = 1; i <= n; ++i) cout << char((rankofnode[i] + 65)) << " ";
  ;
  return 0;
}
