I have a large file of data that will parse and will be putted into Array1 and Array2 to perform a computation but the twist is some of the data doesn't have a computation so the thing that should do is to copy the current data (which is in the Array2) of those data that doesn't have a computation. Below is the sample of what should I do and my problem:
This are the Legend name that have a computation: [A, B, C]
Example:
Legend Array1 Array1 Data Legend Array2 Array2 Data
A[0] 45[0] A[0] 50[0]
B[1] 10[1] C[1] 25[1]
C[2] 15[2] E[2] 10[2]
D[3] 143[3] F[3] 0[3]
E[4] 0[4] B[4] 11[4]
D[5] 150[5]
In the example above you will see a different length of Arrays and that is my problem because I need to get the difference of the data that has a legend name "A","B" and "C" but as you can see there position in the array are different so the tendency is I WILL GET A WRONG COMPUTATION OR WRONG ANSWER. What should I do to fix that problem? How can I match the 2 Arrays to get the correct answers in the computation? Thank you in advance for the help very appreciated. :)