javascript combine two index elements

Solutions on MaxInterview for javascript combine two index elements by the best coders in the world

showing results for - "javascript combine two index elements"
Benjamin
17 Feb 2018
1var array1 = [1, 2, 3, 4];
2var array2 = ["a", "b", "c", "d"];
3
4var newArray = array1.map((e, i) => e + array2[i]);
5console.log(newArray);