online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code   
Language
#include <stdio.h> int main(){ // ํ”„๋กœ๊ทธ๋žจ ์‹œ์ž‘์  int a[5] = {2, 4, 6, 8, 22}; // ์ •์ˆ˜ํ˜• ๋ฐฐ์—ด a ์„ ์–ธ ๋ฐ ์ดˆ๊ธฐํ™” (ํฌ๊ธฐ 5) int *ptr = a; // ๋ฐฐ์—ด๋ช… a๋Š” ๋ฐฐ์—ด์˜ ์‹œ์ž‘ ์ฃผ์†Œ๋ฅผ ์˜๋ฏธ, ์ด๋ฅผ ํฌ์ธํ„ฐ ptr์— ์ €์žฅ // ํฌ์ธํ„ฐ๋ฅผ ์‚ฌ์šฉํ•˜์—ฌ ๊ฐ ์š”์†Œ์— ์ ‘๊ทผ for (int i = 0; i < 5; i++){ printf("*(ptr + %d) = %d\n", i, *(ptr + i)); // ptr์€ ๋ฐฐ์—ด์˜ ์‹œ์ž‘ ์ฃผ์†Œ, *(ptr + i)๋Š” i๋ฒˆ์งธ ์š”์†Œ๋ฅผ ์—ญ์ฐธ์กฐํ•˜์—ฌ ๊ฐ’ ์ถœ๋ ฅ } 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