Dans :
Fonctions PHP
Concepts PHP
Fonctions MySQL
Fonctions HTML
Forum PHP/MySQL
Cours PHP/MySQL
Scripts PHP/MySQL
<?phpfunction fact($x) { $return = 1; for ($i=2; $i < $x; $i++) { $return = gmp_mul($return, $i); } return $return;}echo gmp_strval(fact(1000)) . "\n";?>
Cet exemple va calculer factorielle de 1000 (un grand nombre) très vite.