3v4l.org

run code in 200+ PHP versions simultaneously
<?php $arr = array(0=>1,1=>2); $check = true; unset($arr[0], $check); print_r($arr);
Output for 4.3.0 - 7.4.0
Array ( [1] => 2 )