search_n

rotate and rotate_copy

template <class ForIter>  void rotate(ForIter start, ForIter mid, ForIter end);template <class ForIter, class OutIter>     OutIter rotate_copy(ForIter start, ForIter mid,                         ForIter end, OutIter result);

The rotate( ) algorithm left-rotates the elements in the range specified by start and end so that the element specified by mid becomes the new first element.

The rotate_copy( ) algorithm copies the range specified by start and end, storing the result in result. In the process, it left-rotates the elements so that the element specified by mid becomes the new first element. It returns an iterator to the end of result.




C(s)C++ Programmer's Reference
C Programming on the IBM PC (C Programmers Reference Guide Series)
ISBN: 0673462897
EAN: 2147483647
Year: 2002
Pages: 539

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net