URL Address - page 4

 
Dominik Egert #:
the definition of recursion of of Wikipedia:

A classic example of recursion is the definition of the factorial function, given here in Python code:

The function calls itself recursively on a smaller version of the input (n - 1) and multiplies the result of the recursive call by n , until reaching the base case, analogously to the mathematical definition of factorial.

Recursion in computer programming is exemplified when a function is defined in terms of simpler, often smaller versions of itself. The solution to the problem is then devised by combining the solutions obtained from the simpler versions of the problem. One example application of recursion is in parsers for programming languages. The great advantage of recursion is that an infinite set of possible sentences, designs or other data can be defined, parsed or produced by a finite computer program.


Also take a look at the Ackerman-Function here:

https://en.wikipedia.org/wiki/Ackermann_function


Understanding the implications of a function calling itself is mandatory, if you are using such.


Your WebRequest function keeps calling itself, because you named them the same. The compiler cannot distinguish between your WebRequest and the original WebRequest.

Because you named them the same, and have given them the same parameters list.


Yes I know