Append Array to empty Array

Append Array to empty Array

laurenz_peleman
Not applicable
375 Views
1 Reply
Message 1 of 2

Append Array to empty Array

laurenz_peleman
Not applicable

Dear all

I want to construct an Array of Arrays using the available Array. operators maximally. I start with an empty array A = Array[0] and want to add e.g. the Arrays [1,2,3] and [4,5,6] subsequently, to end up with the Array A = Array[2] = {[1,2,3],[4,5,6]}.

However, using the append operation twice on A, i.e. A.append([1,2,3]) followed by A.append([4,5,6]), I end up with A = {1,2,3,4,5,6}, not really what I want. Is there a simple way to force the append operation to treat the Array parameter as one row element to be added, instead of as a group of separate elements?

Thanks in advance, kind regards

Laurenz Peleman

0 Likes
Accepted solutions (1)
376 Views
1 Reply
Reply (1)
Message 2 of 2

laurenz_peleman
Not applicable
Accepted solution

Question solved, .push did the trick