Array comparison / intersection / difference; move Array contents around.
in
Programming Questions
•
2 years ago
hi,
in supercollider there are methods for comparing / intersect / find difference between etc arrays. i need to do similar operations in processing. are there any of those, for modifying arrays? or is there a different class (maybe from java) that allows such?
what i need: i will have a finite amount of ints. i want to move them in groups between 3 different arrays. for example, they are all in the first array, then i "move" (copy and remove) the first 100 ints to the second array, the from there the first 50 to the third array, then the first 20 back to the first array. every int can be inside of only one array at the same time, either first or second or third, never in two of the arrays.
can anybody give me a hint? thanks a lot, best regards!
florian.
1