3v4l.org

run code in 300+ PHP versions simultaneously
<?php $input = array("a", "b", "c", "d", "e"); $len = count($input); $firsthalf = array_slice($input, 0, intval($len / 2)); $secondhalf = array_slice($input, intval($len / 2)); var_dump($firsthalf, $secondhalf);
Output for rfc.property-hooks, git.master_jit, git.master
array(2) { [0]=> string(1) "a" [1]=> string(1) "b" } array(3) { [0]=> string(1) "c" [1]=> string(1) "d" [2]=> string(1) "e" }

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:
55.6 ms | 2752 KiB | 4 Q