3v4l.org

run code in 300+ PHP versions simultaneously
<?php $json = '{"int": 1, "string" : "mystring"}'; $array = json_decode($json,true); foreach($array AS $key => $value) { echo $key . ": " . gettype($value) . "\n"; }

preferences:
43.4 ms | 402 KiB | 5 Q