PHP - Large Interger mod calculation

Posted by Kami on Stack Overflow See other posts from Stack Overflow or by Kami
Published on 2009-04-17T10:22:55Z Indexed on 2010/05/09 21:08 UTC
Read the original article Hit count: 279

Filed under:
|
|
|

I need to calculate modulus with large number like :

<?php

    $largenum = 95635000009453274121700;

    echo $largenum % 97;

?>

It's not working... beacause $largenum is too big for an int in PHP.

Any idea how to do this ?

© Stack Overflow or respective owner

Related posts about php

Related posts about modulus