3v4l.org

run code in 300+ PHP versions simultaneously
<?php $input = array("red", "green", "blue", "yellow", "1", "2", "3","4"); array_splice($input, -5, 3); print_r($input);

preferences:
38.55 ms | 402 KiB | 5 Q