3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr = Array ( '2018-10-18' => 5, '2018-10-19' => 5, '2018-10-20' => 5, '2018-10-27' => 5, '2018-10-28' => 4, '2018-10-29' => 4, '2018-11-03' => 4 ); Foreach(array_unique($arr) as $v){ $temp = array_keys(array_intersect($arr, [$v])); $new[] = ['start' => current($temp), 'end' => end($temp), 'value' => $v]; } var_dump($new);
Output for git.master, git.master_jit, rfc.property-hooks
array(2) { [0]=> array(3) { ["start"]=> string(10) "2018-10-18" ["end"]=> string(10) "2018-10-27" ["value"]=> int(5) } [1]=> array(3) { ["start"]=> string(10) "2018-10-28" ["end"]=> string(10) "2018-11-03" ["value"]=> int(4) } }

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