Remove Duplicates
Understand how to remove adjacent duplicate elements in C++ containers using the algorithms std::unique and std::unique_copy. Discover how to apply optional binary predicates and the erase-remove idiom to effectively modify data ranges as part of your algorithm toolkit.
We'll cover the following...
We'll cover the following...
With the algorithms std::unique and std::unique_copy, We have opportunities to remove adjacent duplicates. This can be done with and without a binary predicate.