3v4l.org

run code in 300+ PHP versions simultaneously
<?php function arrToStr($arr){ $str = ""; foreach($arr as $a) $str .= $a; return $str; } $lol = array( "why" => ["wont", "this", "work"], "its" => ["pretty", "darn", "annoying"], "hur" => ["dur"] ); $omg = array_slice($lol, 0, 1, count($lol), true); foreach($omg as $wtf => $bbq){ printf("%s: %s", $wtf, printArr($bbq)); }

preferences:
20.85 ms | 402 KiB | 5 Q