3v4l.org

run code in 300+ PHP versions simultaneously
<?php $a = gmp_pow("10", 100); $b = gmp_pow("10", 303); $c = gmp_pow("10", 600); echo "10^100 * 10^600 = ".dumbFormatScientific(gmp_mul($a, $c))." Aka.: \n"; echo gmp_mul($a, $c)."\n"; echo "10^100 * 10^303 = ".dumbFormatScientific(gmp_mul($a, $b))." Aka.: \n"; echo gmp_mul($a, $b)."\n"; function dumbFormatScientific(GMP $input) { $string = gmp_strval($input); $str_arr = str_split($string); $char_cnt = 0; foreach($str_arr as $char) { if($char == 0) { $char_cnt++; } } return "10^".$char_cnt; } ?>
Output for git.master, git.master_jit, rfc.property-hooks
10^100 * 10^600 = 10^700 Aka.: 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 10^100 * 10^303 = 10^403 Aka.: 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
85.05 ms | 403 KiB | 8 Q