Use the correct Array method to remove the last item of the fruits array. code example
Example 1: how to remove last element of array in javascript
let numbers = [1, 2, 3];
numbers.pop();
Example 2: how to remove the last element of an array in javascript
let cars = ['BMW', 'Benz', 'Audi'];
cars.pop(); // ['BMW', 'Benz']