programm for factorial
Answer / koushikgraj
<?php
function get_factorial_value($val)
{
$fact=1;
for($i=$val;$i>=1;$i--)
$fact=$fact*$i;
return $fact;
}
get_factorial_value(6);
?>
| Is This Answer Correct ? | 10 Yes | 1 No |
Tell me how can we change the maximum size of the files to be uploaded?
What are the rules to determine the “truth” of any value which is not already of the boolean type?
How to add different images in php program like a job site.......
Who is the father or inventor of php?
How to call php function from javascript using ajax?
Tell me what is the difference between ereg_replace() and eregi_replace()?
How can I increase my website session?
Tell me what is the difference between the functions strstr() and stristr()?
what is different between PHP and Asp.net?
What is the difference between explode() and split() functions?
What is php static function?
What are the differences between PHP3 and PHP4 and PHP5? what is the current stable version of PHP?