online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code   
Language
/****************************************************************************** Online C++ Compiler. Code, Compile, Run and Debug C++ program online. Write your code in this editor and press "Run" button to compile and execute it. *******************************************************************************/ #include <iostream> using namespace std; int variable = 5; void fun() { cout << "fun() globalne:" << variable << endl;//Globalne, bo innego nie ma int variable = 15; cout << "fun() lokalne:" << variable << endl;//Lokane, bo w tym miejscu kompilator widzi definicję zmiennej lokalnej variable cout << "fun() globalne:" << ::variable << endl;//globalne, bo jasno zasygnalizowałem kompilatorowi przez użycie :: "użyj zmiennej globalnej" } int main() { int variable = 10; fun(); cout << "main() lokalne:" << variable << endl; cout << "main() globalne:" << ::variable << endl; 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