
Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
The Handshake problem's implementation as a recursive function in C language.
Typology: Study Guides, Projects, Research
1 / 1
This page cannot be seen from the preview
Don't miss anything!

int handshake ( int n ) ;
int main () { printf ( " % d \ n " , handshake (25) ) ; return 0; }
handshake ( n ) { if ( n == 0) return 0; else return (( n -1) + handshake (n -1) ) ; }