template <class InIter, class OutIter, class Func>    OutIter transform(InIter start, InIter end,                       OutIter result, Func unaryfunc); template <class InIter1, class InIter2, class OutIter, class Func>     OutIter transform(InIter1 start1, InIter1 end1,                       InIter2 start2, OutIter result,                       Func binaryfunc);

The transform( ) algorithm applies a function to a range of elements and stores the outcome in result. In the first form, the range is specified by start and end. The function to be applied is specified by unaryfunc. This function receives the value of an element in its parameter, and it must return its transformation.

In the second form, the transformation is applied using a binary operator function that receives the value of an element from the sequence to be transformed in its first parameter and the value of an element from the second sequence as its second parameter.

Both versions return an iterator to the end of the resulting sequence.

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