Pro.ID10140 TitleCow Pedigrees Title链接http://10.20.2.8/oj/exercise/problem?problem_id=10140 AC16 Submit79 Ratio20.25% 时间&空间限制描述Farmer John is considering purchasing a new herd of cows. In this new herd, each mother cow gives birth to two children. The relationships among the cows can easily be represented by one or more binary trees with a total of N (3 ≤ N < 200) nodes. The trees have these properties:
How many different possible pedigree structures are there? A pedigree is different if its tree structure differs from that of another pedigree. Output the remainder when the total number of different possible pedigrees is divided by 9901. 输入Multiple test cases, each test case consist of two space-separated integers, N and K , in one line. 输出Description Farmer John is considering purchasing a new herd of cows. In this new herd, each mother cow gives birth to two children. The relationships among the cows can easily be represented by one or more binary trees with a total of N (3 ≤ N < 200) nodes. The trees have these properties:
How many different possible pedigree structures are there? A pedigree is different if its tree structure differs from that of another pedigree. Output the remainder when the total number of different possible pedigrees is divided by 9901. Input Multiple test cases, each test case consist of two space-separated integers, N and K , in one line. Output For each case , output one line : one single integer number representing the number of possible pedigrees MODULO 9901. Sample Input 5 3 Sample Output 2 Hint Two possible pedigrees have 5 nodes and height equal to 3: @ @ Source 样例输入5 3 样例输出2 提示Two possible pedigrees have 5 nodes and height equal to 3: @ @ |