In the program on page 349 that erased a range of elements, what happens if elem1 and elem2 are equal? What if elem2 or both elem1 and elem2 are the off-the-end iterator
belongs to book: C++ Primer|Stanley B.Lippman, Josee Lajoie, Barbara E.Moo|5th Edition| Chapter number:9| Question number:25
All Answers
total answers (1)
                        
        
    
C++ programming
If
`elem1`and`elem2`are equal, then no element will be removed from the container.If
`elem2`or both`elem1`and`elem2`are the off-the-end iterator, then all elements from`elem1`to the last element in the container will be removed.
need an explanation for this answer? contact us directly to get an explanation for this answer