void infinte (long l)
{
printf ("I will never stop #%ld\n", l);
infinte (l+1);
}
I will explain in the easiest way the difference between the function and recursive function in C language. Simple Answer is argument of the function is differ but in the recursive function it is same:) Explanation: Function int function(int,int)// function declaration main() { int n; ...... ...... n=function(a,b); } int function(int c,int d) { ...... ...... ...... } recursive Function: int recursive(int,int)// recursive Function declaration main() { int n; ..... ..... ..... ..... n=recursive(a,b); } int recursive(int a,int b) { ..... .... .... .... } Carefully see, In the recursive Function the function arguments are same.
Yes
A self-referential function in C++, or in any other supporting language, is a recursive function.
Write a function that print a triangle of stars.
non recursive function is excuted faster than recrussive
If you're asking if the c preprocessor supports recursive macros, the answer is no. The preprocessor is single-pass and since the "function" must be defined before it can be referenced, it can not be recursive.
Yes, this can be done. For example for Fibonacci series. You will find plenty of examples if you google for the types of series you need to be generated.
I don't think its possible. Every C++ program must at least have the main function.
I believe, you can use C-function - printf().
i love u darling
There is no such term as "building function" in C++.
Functions in C language may call themselves (ie can be recursive) without restrictions.