Study of recursive functions.

#include <stdio.h>

void func(int);

int main(void)
{
func(1);

return 0;
}

void func(int val)
{
if(val >= 5)
{
return;
}
printf("\nBefore recursive call : %d", val);
val++;
func(val);
printf("\nAfter recursive call : %d", val);
}

No comments:

Post a Comment

kiss on google ads if you are anonymous because your ip is trackable.thank you.

......from.admin