#include <bits/stdc++.h>
using namespace std;
const int N = 1e5 + 1;
int n;
vector<int> g[N];
pair<int, int> dfs(int cur, int p, const int &k) {
  int v[2] = {0, 0};
  int complete = 0;
  for (auto nxt : g[cur])
    if (nxt != p) {
      auto ret = dfs(nxt, cur, k);
      complete += ret.first;
      int incomplete = ret.second;
      for (int i = 0; i < 2; ++i)
        if (incomplete > v[i]) swap(v[i], incomplete);
    }
  if (v[0] + v[1] + 1 >= k)
    return make_pair(complete + 1, 0);
  else
    return make_pair(complete, v[0] + 1);
}
void solve(int kl, int kr, int vl, int vr) {
  if (vl == vr) {
    for (int i = kl; i <= kr; ++i) printf("%d\n", vl);
    return;
  }
  int km = (kl + kr) >> 1;
  int vm = dfs(1, 1, km).first;
  if (kl < km) solve(kl, km - 1, vl, vm);
  printf("%d\n", vm);
  if (km < kr) solve(km + 1, kr, vm, vr);
}
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n - 1; ++i) {
    int u, v;
    scanf("%d %d", &u, &v);
    g[u].push_back(v);
    g[v].push_back(u);
  }
  int k, ans;
  solve(1, n, dfs(1, 1, 1).first, dfs(1, 1, n).first);
}
