|
Can I just clarify the problem?
It seems you're looking to remove rows which (in, say, column 1) contain some of the same letters. Or is it the first letter? Or is it the one with maximum length in the first column, given that the second column matches? Or a whole number of other possibilities...
To help us understand what you need, what would be the outcome of your ideal function if it was given the following arrays:
A = {'XYZ' '1'
'X' '1'
'Y' '1'}
B = {'XYZ' '1'
'XYZQ' '1'}
C = {'XYZQ' '1'}
'XYZ' '1'}
D = {'XYZQ' '1'
'Q' '1'}
E = {'R' '1'
'R' '2'
'RS' '2'}
F = {'ABCD' '1'
'PQRSWEA' '1'
'APQRSWE' '1'
'AB' '1'}
G = {'ABCD' '1'
'PQRSWEA' '1'
'APQRSWE' '1'
'ABQWERTYUIOP' '1'}
??
That might help us figure out what you're looking for a bit better.
As an initial hint, I've a feeling you'd be looking to use some combination of unique with logical statement(s).
Kind Regards
Tom Clark
|