text cover

Data Abstraction and Problem Solving with C++

Walls and Mirrors

by Frank M. Carrano

Addison Wesley Logo

c02p093.cpp

Go to the documentation of this file.
00001 
00022 int c(int n, int k)
00023 {
00024    if ( (k == 0) || (k == n) )
00025       return 1;
00026    else if (k > n)
00027       return 0;
00028    else
00029       return c(n-1, k-1) + c(n-1, k);
00030 }  // end c

Generated on Sun Aug 27 11:05:08 2006 for AWLogo by  doxygen 1.4.6