3v4l.org

run code in 300+ PHP versions simultaneously
<?php ini_set("precision", 20); // from 246 $from = "8.2" * "30"; // to 342 $to = "11.4" * "30"; printf("from %.20f to %.20f\n", $from, $to); $a = []; for ($i = $from; $i <= $to; $i++) { if (round($i) != floor($i)) { printf("index %.20f will be truncated to %d\n", $i, $i); } if ($i == 246) { echo "No output at all!"; } if ($i == 250) { echo "Still no output..."; } if ($i == 256) { echo "Still no output..."; } if ($i == 257) { echo "It works for {$i} and further numbers"; } $a[$i] = "test" . $i; } var_dump($a);

preferences:
59.31 ms | 411 KiB | 5 Q