Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

programm for factorial

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


Please Help Members By Posting Answers For Below Questions

Tell me how is it possible to propagate a session id?

981


What kind of variable is age?

1051


What are the difference between array_keys() and array_key_exists() in php?

1009


What is static method php?

950


What does the scope of variables means?

961


Write a select query that will be displayed the duplicated site name and how many times it is duplicated?

966


What is encapsulation in php?

933


What does the unlink() function mean?

1010


Is it more secure to use cookies to transfer session ids?

901


Which is better #define or enum?

906


Do you know is it possible to extend the execution time of a php script?

982


Is php a web server?

934


What is faster?

953


What is polymorphism php?

934


What is echo and print in php?

901