void count_to_ten(int count) { if (count < 10) { printf("Count: %d\n", count); count_to_ten(count + 1); } }
void count_to_ten ( int count ) { // we only keep counting if we have a value less than ten if ( count < 10 ) { count_to_ten( count + 1 ); } }
void count_to_ten ( int count ) { /* we only keep counting if we have a value less than ten */ if ( count < 10 ) { printf("\nbefore call %d",count); count_to_ten( count + 1 ); printf("\n:after call %d",count); } }
int main() { //recurse(1); /* First function call so it starts at 1 */ count_to_ten(0); return 0; }
int main () { count_to_ten (0); }