Course · Section 9: Data Structures, Modern Operators and Strings · Lecture 112: Rest Pattern and Parameters
Implement `splitFirst(arr)` returning `[first, rest]` where `rest` is an array of the remaining elements, using a rest element.
+ 1 hidden test run on Submit.
The rest pattern gathers everything after the first element into a new array.
Run your code to see results.