Exercise: Tag Dispatching
Test your understanding of the tag dispatching idiom.
We'll cover the following
Problem statement
Read the following code and extend it using the advance_
function provided. Write code in the main
function to do the following:
Advance an iterator of a
std::vector
by a positive distanceAdvance an iterator of a
std::list
by a positive distance and then by a negative distanceAdvance an iterator of a
std::forward_list
by a positive distance
Coding exercise
Get hands-on with 1400+ tech skills courses.