Pro.ID21833 TitleCounting spanning trees Title链接http://10.20.2.8/oj/exercise/problem?problem_id=21833 AC0 Submit0 Ratio- 时间&空间限制描述Everyone knows spanning trees, especially MST problem. But most of them are not familiar with degree constrained spanning tree. a degree-constrained spanning tree is a spanning tree which the maximum vertex degree is limited to a certain constant d. Given two integers n and d, your task is to count the number of degree constrained spanning trees of a (labeled) complete graph with n vertices. 输入Each line contains two integers n, d. 1 ≤ n ≤ 100 , 1 ≤ d ≤ 100. 输出Description Everyone knows spanning trees, especially MST problem. But most of them are not familiar with degree constrained spanning tree. a degree-constrained spanning tree is a spanning tree which the maximum vertex degree is limited to a certain constant d. Given two integers n and d, your task is to count the number of degree constrained spanning trees of a (labeled) complete graph with n vertices. Input Each line contains two integers n, d. 1 ≤ n ≤ 100 , 1 ≤ d ≤ 100. Output For each query, output a line which contains only one integer, the number of degree constrained spanning trees of a (labeled) complete graph with n vertices. This number may be very large, so output the answer modulo 20090829. Sample Input 3 1 Sample Output 0 Source 样例输入3 1 样例输出0 作者 |