Is there a function that I can use that given a few vectors which elements are common to all?
a.push_back( 1 );
a.push_back( 2 );
a.push_back( 3 );
a.push_back( 4 );
b.push_back( 2 );
b.push_back( 4 );
Something that will give me back the answer of 2 and 4? (The results would be stored in another vector).
What if I have more than 2 vectors to compare - would I somehow call this function against each pair? (ie a vs. b, b vs. c, a vs. c?)