I have an array like
@array = (1 2 3 4 5 6 7 8 10 14 15 20,
7 14 20,
21 22 23 24 40 50);
This array has 3 elements .
a)I want to combine the elements even if they have one number common such as 14 in first and second element.and then I want to combine these elements.How do I do this?Please help.
b) How do I merge two elements if all the elements of one element are present in other as in 0th and first element?
Please help!
I have around 30 elements in my array.