3v4l.org

run code in 300+ PHP versions simultaneously
<?php $input = array('country1' => 'CountryOne', 'country2' => 'Country Two'); print_r($input); $output = array_map(function($each) { return array('code' => key($each), 'name' => current($each)); }, array_chunk($input, 1, true)); print_r($output); ?>
Output for git.master, git.master_jit, rfc.property-hooks
Array ( [country1] => CountryOne [country2] => Country Two ) Array ( [0] => Array ( [code] => country1 [name] => CountryOne ) [1] => Array ( [code] => country2 [name] => Country Two ) )

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:
30.36 ms | 406 KiB | 5 Q