I've checked the forum to see if i'll have an answer to this question but so far, i haven't. I have this 2 dimensional array that i want to sum up their values if they are the same. Here is an example.
CAR CAH 394
CAR CAH 96
CAR CAP 268
DOR CAF 71
DOR CAP 96
DOR CAP 268
VAC GILAB 71
After sorting the array, i have the above values. How can i add up all the duplicates in the arraylist. In this case, it will affect CAR|CAH and DOR|CAP. So instead of returning the duplicates, its goint to return one with the combined sum.
i want to sum up their values if they are the sameif what are the same? Your question isn't exactly clear. You have two strings and a number. Are you summing them if the two strings are the same as another row? Put your source and you expected output in the question along with what you've tried.