www.pudn.com > huffman.rar > MyMath.c
#include "MyMath.h" #include "MyAssert.h" #include "Ulti.h" #include#include #include /*Attention when n is big ,this algorithm will have no little effect*/ long combination(int n,int m)/*output the group num from select from n element*/ { /*Algorithm Reason Cm,n=n!/(m!*(n-m)!) */ assertF(n>=m&&n<17,"in combination n =0&&n<17,"in jieCheng n is<0 or n is too big!\n"); if(n==1||n==0)return 1; else return n*jieCheng(n-1); }