I have a question about how to efficiently search two containers in order to find same items.
For example, I have two list A, B
, and I want to figure out all of matched items in list B for list A.
In this case, I need to have two loopS, one inside another. It is not good, because for each items of A, I do a whole search in B.
Do you have some ideas or standard lib (boost is OK) to solve it ;) ?
Thanks a lot!