online compiler and debugger for c/c++

code. compile. run. debug. share.
Source Code    Language
#include<stdio.h> int main() { FILE *fp1,*fp2; char c; fp1 = fopen("./file.txt","r"); if(fp1 == NULL) { printf("Unable to open file\n"); return -1; } fp2 = fopen("./file1.txt","w"); if(fp2 == NULL) { printf("Unable to open file\n"); return -1; } while((c = fgetc(fp1)) != EOF) { fputc(c,fp2); printf("%c", c); } fclose(fp2); fclose(fp1); return 0; }
Hello world
Hello world

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