Answer Posted / 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 |
Post New Answer View All Answers
What is the function mysql_pconnect() useful for?
How to reset/destroy a cookie in php?
How error handling is being handled by php?
What is url encoding and decoding in php?
What is json php?
How can we upload a file in php?
How to find the index of an element in an array php?
What does $_cookie means?
Why php is used with mysql?
What is the difference between html and php?
Can we extend two classes in php?
How to specify argument default values?
What is a variable cost example?
How to remove duplicate values from a PHP Array?
What is the function of mysql_real_escape_string in php?