3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = range(0,10); $slice = array_slice($array,12); // same with and without the offset parameter! print_r($slice); // Empty! $array = range(0,5); $slice = array_slice($array,3); print_r($slice); // As expected 3 elements!

preferences:
24.51 ms | 406 KiB | 5 Q