#include <bits/stdc++.h>
using namespace std;
const int oo = 1e9 + 7;
const double pi = 2 * acos(0.0);
const long long mod = 1e9 + 7;
const int N = 1e5 + 10;
const int LOG_N = 20;
vector<int> c_par, subTree;
vector<set<int>> adj;
vector<vector<int>> tree;
int tot, n;
int dep[N];
int par[LOG_N][N];
int LOG[N];
void dfs(int u = 1, int p = -1, int d = 0) {
  dep[u] = d;
  par[0][u] = p;
  for (int i = 1; (1 << i) <= d; ++i) {
    par[i][u] = par[i - 1][par[i - 1][u]];
  }
  for (int v : adj[u]) {
    if (v != p) {
      dfs(v, u, d + 1);
    }
  }
}
void computeLog() {
  LOG[0] = -1;
  for (int i = 1; i <= n; ++i) {
    LOG[i] = LOG[i - 1] + !(i & (i - 1));
  }
}
void buildLCA() {
  dfs();
  computeLog();
}
int getAncestor(int u, int k) {
  while (k > 0) {
    int x = k & -k;
    k -= x;
    u = par[LOG[x]][u];
  }
  return u;
}
int getLCA(int u, int v) {
  if (dep[u] > dep[v]) {
    swap(u, v);
  }
  v = getAncestor(v, dep[v] - dep[u]);
  if (u == v) {
    return u;
  }
  for (int i = LOG[dep[u]]; i >= 0; --i) {
    if (par[i][u] != par[i][v]) {
      u = par[i][u];
      v = par[i][v];
    }
  }
  return par[0][u];
}
int getDistance(int u, int v) {
  return dep[u] + dep[v] - 2 * dep[getLCA(u, v)];
}
void dfs1(int u, int p) {
  subTree[u] = 1;
  tot++;
  for (auto v : adj[u])
    if (v != p) dfs1(v, u), subTree[u] += subTree[v];
}
int centroid(int u, int p) {
  for (auto v : adj[u])
    if (v != p && subTree[v] > tot / 2) return centroid(v, u);
  return u;
}
int getCentroid(int u, int p) {
  tot = 0;
  dfs1(u, p);
  return centroid(u, p);
}
int decompose(int u, int p) {
  int cen = getCentroid(u, p);
  for (auto v : adj[cen]) {
    adj[v].erase(cen);
    int c = decompose(v, cen);
    c_par[c] = cen;
    tree[c].push_back(cen);
    tree[cen].push_back(c);
  }
  adj[cen].clear();
  return cen;
}
vector<char> ans;
bool valid = true;
void sol(int u, int p = -1, int cur = 0) {
  if (cur == 26) {
    valid = false;
    return;
  }
  ans[u] = ('A' + cur);
  for (auto v : tree[u])
    if (v != p) sol(v, u, cur + 1);
}
void solve(int t) {
  cin >> n;
  adj.resize(n + 1);
  c_par.resize(n + 1, -1);
  subTree.resize(n + 1);
  tree.resize(n + 1);
  for (int i = 1; i < n; i++) {
    int a, b;
    cin >> a >> b;
    adj[a].insert(b);
    adj[b].insert(a);
  }
  int cen = decompose(1, -1);
  ans.resize(n + 1);
  sol(cen);
  if (!valid) {
    cout << "Impossible!" << endl;
    return;
  }
  for (int i = 1; i <= n; i++) cout << ans[i] << " ";
  cout << endl;
}
int main() {
  int t = 1;
  int cnt = 1;
  while (t--) solve(cnt++);
}
