fork download
  1.  
  2. #include <functional>
  3.  
  4. int foo(int a, int b) { return a - b; }
  5.  
  6. int main()
  7. {
  8. int arg =10 ;
  9. std::bind(foo, 1, std::placeholders::_1)(arg);
  10. std::bind(foo, 1, std::placeholders::_1)(10);
  11. }
Success #stdin #stdout 0s 3292KB
stdin
Standard input is empty
stdout
Standard output is empty