STL (Standard Template Library) Part2

Function Adapters
A function adapter is a function object that enables the combining of function objects with each other, with certain values, or with special function.

The expression bind2nd(greater(), 42) produces a cobmined function object that checks whetehr an int value is greater than 42. In fact, bind2nd transforms a binary function object, such as greater<>(), into a unary function object. Thus, in this example it always calls greater<> with 42 as the second argument.

The following are the list of predefined function adapter classes in STL:
* bind1st(op, value) ==> op(value, param)
* bind2nd(op, value) ==> op(param, value)
* not1(op) ==> !op(param)
* not2(op) ==> !op(param1, param2)