组合 二项式定理
摘要:
#include <stdio.h>#include <string.h>#include <stdlib.h>int c[1000];int c1[100][100];/* 排列与组合 c(n,k) = n ! / ( k! * (n - k)!)*//*1.求组合数利用等式2.利用杨辉三角*//*二项式定理(a + b) ^n = for k = 0 to nc(n,k) = a ^(n - k) * b ^k;*/ int main( ){ int i, j, n; while (scanf("%d", &n), n) { 阅读全文
posted @ 2011-07-27 20:58 more think, more gains 阅读(199) 评论(0) 推荐(0) 编辑