-
Content Count
21 -
Joined
-
Last visited
-
Days Won
2
File Comments posted by Z3R0
-
-
I would like to see an array_diff(.@array, .@array2)....
something like...
@array1[0] = 1, 2, 3;
@array2[0] = 1, 2, 3, 4, 5, 6, 7, 8, 9;
array_diff(@array1, @array2) = [ ]
array_diff(@array2, @array1) = [ 4, 5, 6, 7, 8 ]
First Array contains all items you WANT with any/all items from Second Array.... so in the first example with 1,2,3 it only checks against 1,2,3 existing in [1,2,3,4,5,6,7,8]
Where as in the second example it checks [ 1,2,3,4,5,6,7,8 ] for any or all occurrences of [1,2,3] and returns the ones that don't match.. [4,5,6,7,8 ]
Array manipulation functions
in Quest, Shops, Functions & Algorithms
264 14Posted
Couldn't find a place to add bug report from here... so here it goes...
array_push skips 0 values, where as setarray() does not
I tested with the following script