3v4l.org

run code in 300+ PHP versions simultaneously
<?php var_dump(array_diff( [ 'q1' => true, 'q2' => true, 'q3' => false, 'q4' => false, ], [ 'q1' => false, 'q2' => false, 'q3' => false, 'q4' => false, ] ));
based on DlnBr
Output for 5.6.0 - 5.6.28, 7.0.0 - 7.0.20, 7.1.0 - 7.1.20, 7.2.6 - 7.2.33, 7.3.16 - 7.3.24, 7.4.0 - 7.4.13, 8.0.0
array(2) { ["q1"]=> bool(true) ["q2"]=> bool(true) }