3v4l.org

run code in 300+ PHP versions simultaneously
<?php echo PHP_INT_MAX, "\n"; $a = array('a' => PHP_INT_MAX); /* it works OK if you put PHP_INT_MAX-1 here */ print_r($a); $j = json_encode($a); echo $j, "\n"; $b = json_decode($j); /* produces the incorrect error message */ print_r($b);

preferences:
13.62 ms | 406 KiB | 5 Q