3v4l.org

run code in 300+ PHP versions simultaneously
<?php $entries = array( "111 222 465", "666 123 412", "000 999", ); $test = array(111, 465, 555, 666, 777); foreach ($entries as $key => $entry) { $plotsTotal1 = explode(' ', $entry); $plotsTotal2 = array_filter($plotsTotal1); $matches = array_intersect($test, $plotsTotal2); if (count($matches) > 0) { echo 'Entry ' . $key. ' contains ' . implode(',', $matches) . "\n"; } }
Output for git.master, git.master_jit, rfc.property-hooks
Entry 0 contains 111,465 Entry 1 contains 666

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:
60.07 ms | 401 KiB | 8 Q