How can I use the array_slice function to get a portion of an array in PHP? Example code: - Biz Tech

How can I use the array_slice function to get a portion of an array in PHP? Example code:

Listen
$fruits = array("apple", "banana", "orange", "grape", "peach");

$sliced_fruits = array_slice($fruits, 1, 3);

print_r($sliced_fruits);