Starting from vector vector unsigned int ...
vector<vector<unsigned short int> > matrix; vector<unsigned short int> row;
I would like to combine conjugate sets (these are vectors with common elements).
To enter as input:
matrix[0] = {0, 1, 2} matrix[1] = {1, 10} matrix[3] = {9} matrix[4] = {2, 8} matrix[5] = {7}
as output:
matrix[0] = {0, 1, 2, 10, 8}
What is the most effective solution to this problem? Regards, Vi.
source share