算数仿函数-取反
#include <iostream>
#include <functional>
using namespace std;
int main()
{
negate<int> n;
cout << n(10) << endl;
return 0;
}
$ ./a.out
-10
#include <iostream>
#include <functional>
using namespace std;
int main()
{
negate<int> n;
cout << n(10) << endl;
return 0;
}
$ ./a.out
-10