#include <bits/stdc++.h>
using namespace std;
const int maxn = 100 + 2, inf = 1e9 + 10, M = 1e9 + 7;
int n, adj[maxn][maxn], C[maxn][maxn], B[maxn];
int power(int a, int b) {
  int ans = 1;
  while (b > 0) {
    if (b & 1) {
      ans = 1ll * ans * a % M;
    }
    a = 1ll * a * a % M;
    b >>= 1;
  }
  return ans;
}
int p[maxn];
int A[maxn][maxn];
int det(int tmp[][maxn], int size) {
  for (int i = 0; i < size; i++) {
    for (int j = 0; j < size; j++) {
      A[i][j] = tmp[i][j];
    }
    p[i] = i;
  }
  int ans = 1;
  for (int i = 0; i < size; i++) {
    int j = i;
    while (A[i][p[j]] == 0) {
      j++;
    }
    if (j == size) {
      return 0;
    }
    if (i != j) {
      ans = M - ans;
      swap(p[i], p[j]);
    }
    ans = 1ll * ans * A[i][p[i]] % M;
    int x = power(A[i][p[i]], M - 2);
    for (int k = 0; k < size; k++) {
      A[k][p[i]] = 1ll * A[k][p[i]] * x % M;
    }
    for (int j = i + 1; j < size; j++) {
      int y = A[i][p[j]];
      for (int k = 0; k < size; k++) {
        A[k][p[j]] = (A[k][p[j]] + M - 1ll * A[k][p[i]] * y % M) % M;
      }
    }
  }
  return ans;
}
bool gauss(int A[][maxn], int size) {
  for (int i = 0; i < size; i++) {
    p[i] = i;
  }
  for (int i = 0; i < size; i++) {
    int j = i;
    while (A[i][p[j]] == 0) {
      j++;
    }
    if (j == size) {
      return 0;
    }
    if (i != j) {
      swap(p[i], p[j]);
    }
    int x = power(A[i][p[i]], M - 2);
    B[p[i]] = 1ll * B[p[i]] * x % M;
    for (int k = 0; k < size; k++) {
      A[k][p[i]] = 1ll * A[k][p[i]] * x % M;
    }
    for (int j = 0; j < size; j++) {
      if (j != i) {
        int y = A[i][p[j]];
        B[p[j]] = (B[p[j]] + M - 1ll * B[p[i]] * y % M) % M;
        for (int k = 0; k < size; k++) {
          A[k][p[j]] = (A[k][p[j]] + M - 1ll * A[k][p[i]] * y % M) % M;
        }
      }
    }
  }
  return 1;
}
int from[maxn], to[maxn];
int solve(int x) {
  for (int i = 0; i < n - 1; i++) {
    for (int j = 0; j < n - 1; j++) {
      if (i == j) {
        adj[i][j] = n - 1;
      } else {
        adj[i][j] = M - 1;
      }
    }
  }
  for (int i = 0; i < n - 1; i++) {
    int a = from[i], b = to[i];
    if (a >= 0 && b >= 0) {
      adj[a][b] -= x;
      adj[b][a] -= x;
    }
    if (a >= 0) {
      adj[a][a] += x;
    }
    if (b >= 0) {
      adj[b][b] += x;
    }
  }
  return det(adj, n - 1);
}
int32_t main() {
  scanf("%d", &n);
  for (int i = 0; i < n - 1; i++) {
    scanf("%d%d", from + i, to + i);
    from[i] -= 2;
    to[i] -= 2;
  }
  for (int i = 0; i < n; i++) {
    B[i] = solve(i);
  }
  for (int i = 0; i < n; i++) {
    for (int j = 0; j < n; j++) {
      C[i][j] = power(j + 1, i);
    }
  }
  if (gauss(C, n) == 0) {
    printf("BUG\n");
    return 0;
  }
  for (int i = 0; i < n; i++) {
    printf("%d\n", B[p[i]]);
  }
}
