how javascript spread operator works 3f

Solutions on MaxInterview for how javascript spread operator works 3f by the best coders in the world

showing results for - "how javascript spread operator works 3f"
Alejandro
02 Sep 2016
1var num = [2, 4, 6, 8, 10];
2console.log(...num)
3//expected output: 2 4 6 8 10
4console.log(88, ...num, 99) 
5// added extra new elements before and after the spread operator
6//expected output: 88 2 4 6 8 10 99