3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $arrayOld = [1, 2, 3, 4, 5]; $arrayNew = [1, 4, 5, 6, 7]; $n = array_diff($arrayOld, $arrayNew); print_r($n);
based on hun5l
Output for 5.5.0 - 7.2.6
Array ( [1] => 2 [2] => 3 )