Is it possible to merge (or maybe convert?) two large 1D arrays (of tens of thousands of items) into one 2D array so that columns of 2D array are the element wise items from each of the 1D array?
I mean the following:
a1 = [1,2,3,4,5,6,7,8,9,10]
a2 = [101,102,103,104,105,106,107,108,109,110]
result = [[1,101],[2,102],[3,103],[4,104],[5,105],[6,106],[7,107],[8,108],[9,109],[10,110]]
There are a few possible methods given in Python in this Merge Link here and I have to do exactly the same but in Javascript. Trying concat, merge but doesn't give the expected result.
Thanks