The Array Concat Method | JavaScript

preview_player
Показать описание


What is “concat” in JavaScript?
The concat() method is used to merge two or more arrays. This method does not change the existing arrays, but instead returns a new array.
The concat method creates a new string
We have an array with Rafiki and “Curious George” in one array
and King Kong and Caesar in another
if we use concat they will all be in the same array
The concat method creates a new array consisting of the elements in the object on which it is called
Рекомендации по теме
join shbcf.ru