3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $a1 = array( 'one', 'two', 'three', 'four' ); $a2 = array_diff($a1, $a1); var_dump($a2); $a2[] = 'five'; var_dump($a2);
based on JkrTn
Output for hhvm-3.12.0, 7.0.0 - 7.1.0
array(0) { } array(1) { [0]=> string(4) "five" }
Output for hhvm-3.10.0

Process exited with code 153.
Output for 4.3.0 - 5.6.28
array(0) { } array(1) { [4]=> string(4) "five" }