PHP
downloads | documentation | faq | getting help | mailing lists | reporting bugs | php.net sites | links | conferences | my php.net

search for in the

Fonctions GMP> <Constantes pré-définies
Last updated: Fri, 05 Sep 2008

view this page in

Exemples

Exemple #1 Factorielle avec GMP

<?php
function 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.



add a note add a note User Contributed Notes
Exemples
There are no user contributed notes for this page.

Fonctions GMP> <Constantes pré-définies
Last updated: Fri, 05 Sep 2008
 
 
show source | credits | stats | sitemap | contact | advertising | mirror sites