Javascript - Write program to Use the concat() method to concatenate two arrays.

Requirements

Use the concat() method to concatenate two arrays: girls and boys.


var girls = ["Oracle", "Jerry"];
var boys = ["Json", "Jack", "Tom"];

Hint

Syntax hint

array1.concat(array2)

Demo

var girls = ["Oracle", "Jerry"];
var boys = ["Json", "Jack", "Tom"];
var children = girls.concat(boys);
console.log( children );//from  ww  w. j  a  v  a2 s  .co m

Result