#t459. 找树根和孩子

找树根和孩子

Background

Special for beginners, ^_^

Description

给定一棵树,输出树的根 rootroot,孩子最多的结点 maxmax 以及他的孩子。

Format

Input

第一行:nn(结点数 ≤100\le 100),mm(边数 ≤200\le 200)。

以下 mm 行;每行两个结点 xx 和 yy,表示 yy 是 xx 的孩子(x,y≤100x,y\le 100)。

Output

第一行:树根:rootroot。

第二行:孩子最多的结点 maxmax。

第三行:maxmax 的孩子。

Samples

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

Limitation

1s, 1024KiB for each test case.