Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- set_time_limit(0);
- function bcfact($fact, $scale = 100)
- {
- $sonuc=1;
- while($fact > 1)
- {
- $fact = bcsub($fact, '1');
- $sonuc = bcmul($sonuc, $fact, $scale);
- }
- return $sonuc;
- }
- echo strlen(bcfact(10000));
- ?>
Add Comment
Please, Sign In to add comment