1#include<stdio.h>
2#include<string.h>
3 __int64 C(__int64 n, __int64 m)
4 {
5 __int64 i, j;
6 if (m > n/2) m = n - m;
7 for (i = 1, j = 1;i <= m; i++)
8 {
9 j = j * (n + 1 - i) / i;
10 }
11 return j;
12 }
13int main ()
14{
15 int i,j,t;
16 __int64 k1,k2,k;
17 __int64 m,n;
18
19 while(scanf("%I64d%I64d",&n,&m)!=EOF&&n||m)
20 {
21 t=m>n?n:m;
22
23 printf("%I64d\n",C(m+n,t));
24 }
25 return 1;
26}
27
posted on 2009-01-27 14:04
混沌的云 阅读(131)
评论(0) 编辑 收藏 引用