online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code   
Language
#include<functional> #include<iostream> template < class T, typename F > T fn(T a, T b, F f) { return f<T>()(a,b); } template<class T> struct X { template < typename F> T foo(T a, T b, F f) { return fn<T, F>(a,b,f); } }; int main() { int a = 1; int b = 1; X<int> f; std::cout<< f.foo(a,b, std::plus<int>); return 0; }

Compiling Program...

Command line arguments:
Standard Input: Interactive Console Text
×

                

                

Program is not being debugged. Click "Debug" button to start program in debug mode.

#FunctionFile:Line
VariableValue
RegisterValue
ExpressionValue