Standard C++ Library Class Reference

transform(vec1.begin(), vec1.end(), vec2.begin(), vecResult.begin(),
greater<int>());
After this call to transform, vecResult(n) will contain a "1" if vec1(n) was greater than vec2(n) or a "0" if vec1(n)
was less than or equal to vec2(n).
Warnings
If your compiler does not support default template parameters, then you need to always supply the Allocator
template argument. For instance, you'll have to write :
vector<int, allocator>
instead of
vector<int>
See Also
Function Objects