online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code    Language
#include <iostream> #include <vector> #include <string> using std::vector; using std::string; using std::cout; class Point { private: int x, y; public: Point() { cout << ">> empty constructor called.\n"; } Point(int x1, int y1) { x = x1; y = y1; cout << ">> Normal constructor called.\n"; } // Copy constructor Point(const Point& p2) { x = p2.x; y = p2.y; cout << ">> Copy constructor called.\n"; } }; int main() { int n = 3; std::vector<Point> points; for (int i = 0; i < n; i++) { cout << "=== " << i << " ===\n"; points.push_back(*(new Point(1, 2))); } 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