3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function array_diff_b($array1, $array2) { $diff = array_diff($array1, $array2); return (empty($diff)) ? TRUE : FALSE; } $a = array ('v1', 'v3', 'v4'); $b = array ('v1', 'v24', 'v3', 'v4', 'v5'); $result = array_diff_b($a, $b); var_dump($result);
Output for 4.3.0 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
bool(true)