Next : Rotate, Previous : Unique, Top : Table of Contents
reverse (BidirectionalIterator first, BidirectionalIterator last) | Function |
templateFor each non-negative integer i <= (last - first)/2, reverse applies swap to all pairs of iterators first + i, (last - i) - 1. Exactly (last - first)/2 swaps are performed.void reverse(BidirectionalIterator first, BidirectionalIterator last);
OutputIterator reverse_copy (BidirectionalIterator first, BidirectionalIterator last, OutputIterator result) | Function |
templateOutputIterator reverse_copy(BidirectionalIterator first, BidirectionalIterator last, OutputIterator result);
reverse_copy copies the range [first, last) to the range [result, result + (last - first)) such that for any non-negative integer i < (last - first) the following assignment takes place: *(result + (last - first) - i) = *(first + i). reverse_copy returns result + (last - first). Exactly last - first assignments are done. The result of reverse_copy is undefined if [first, last) and [result, result + (last - first)) overlap.
|