Writing Recursive Functions

How to Write Recursive Functions

A recursive procedure is one that calls itself. Example is as follows –
The following procedure uses recursion to calculate the factorial of its original argument.
Function factorial(ByVal n As Integer) As Integer
If n <= 1 Then
Return 1
Return factorial(n – 1) * n
End If
End Function


Popular posts from this blog

Testing Webservice with SoapUI Having Windows Authentication

Data Driven Testing Using Selenium -WebDriver in Python

How to Re-run Failed Scenarios in Cucumber