We have a tree with N vertices numbered 1 to N. The i-th edge in this tree connects Vertex a_i and b_i. For each k=1, ..., N, solve the problem below:

* Consider writing a number on each vertex in the tree in the following manner:
* First, write 1 on Vertex k.
* Then, for each of the numbers 2, ..., N in this order, write the number on the vertex chosen as follows:
* Choose a vertex that still does not have a number written on it and is adjacent to a vertex with a number already written on it. If there are multiple such vertices, choose one of them at random.
* Find the number of ways in which we can write the numbers on the vertices, modulo (10^9+7).

Constraints

* 2 \leq N \leq 2 \times 10^5
* 1 \leq a_i,b_i \leq N
* The given graph is a tree.

Input

Input is given from Standard Input in the following format:


N
a_1 b_1
:
a_{N-1} b_{N-1}


Output

For each k=1, 2, ..., N in this order, print a line containing the answer to the problem.

Examples

Input

3
1 2
1 3


Output

2
1
1


Input

2
1 2


Output

1
1


Input

5
1 2
2 3
3 4
3 5


Output

2
8
12
3
3


Input

8
1 2
2 3
3 4
3 5
3 6
6 7
6 8


Output

40
280
840
120
120
504
72
72
#include<bits/stdc++.h>
using namespace std;
template<typename T>inline void read(T& t)
{T f=1;char ch=getchar();t=0;
while(ch<'0'||ch>'9'){if(ch=='-')f=-f;ch=getchar();}
while(ch>='0'&&ch<='9')t=t*10+ch-'0',ch=getchar();t*=f;}
template <typename T,typename... Args>
inline void read(T& t, Args&... args)
{read(t);read(args...);}
int n;
const long long p=1e9+7;
inline long long power(long long x,long long k)
{
	long long re=1;
	for(;k;k>>=1,x=x*x%p)if(k&1)re=re*x%p;
	return re;
}
long long fic[200005];
long long size[200005],f[200005];
int head[200005],ne[400005],to[400005],total=1;
inline void add(int a,int b)
{
	total++;
	to[total]=b;
	ne[total]=head[a];
	head[a]=total;
}
void dfs1(int now,int fa)
{
	size[now]=1;
	for(int i=head[now];i;i=ne[i])
		if(to[i]!=fa)
		{
			dfs1(to[i],now);
			size[now]+=size[to[i]];
		}
	f[1]=f[1]*size[now]%p;
}
void dfs2(int now,int fa)
{
	if(now!=1)
		f[now]=f[fa]*power(size[now],p-2)%p*(n-size[now])%p;
	for(int i=head[now];i;i=ne[i])
		if(to[i]!=fa)
			dfs2(to[i],now);
}
int main()
{
	read(n);
	for(int i=1,x,y;i<n;i++)read(x,y),add(x,y),add(y,x);
	f[1]=1;
	dfs1(1,0);
	dfs2(1,0);
	long long tp=1;
	for(int i=1;i<=n;i++)tp=tp*i%p;
	for(int i=1;i<=n;i++)
		printf("%lld\n",tp*power(f[i],p-2)%p);
	return 0;
}
