online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code   
Language
// Example program #include <iostream> #include <string> #include <optional> #include <memory> class A { public: A(int v): val{v} {} int val; }; class B { public: B(std::shared_ptr<A>& a): a{a} {} const std::shared_ptr<A> a; }; int main() { std::shared_ptr<A> a = std::make_shared<A>(3); std::optional<B> b; b = std::make_optional<B>(a); }

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