Question:What is recursive function? 

Answer A recursive function is a function that calls itself during its execution. This enables the function to repeat itself several times, outputting the result and the end of each iteration. Below is an example of a recursive function.

function Count (integer N)    
if (N <= 0) return "Must be a Positive Integer";    
if (N > 9) return "Counting Completed";    
else return Count (N+1);
end function 


Deprecated: html_entity_decode(): Passing null to parameter #1 ($string) of type string is deprecated in D:\webserver\www\vcampusbd.com\answers\column_answer_two.php on line 128
+ Report
Total Preview: 1116
What is recursive function?
Copyright © 2024. Powered by Intellect Software Ltd