Oh! I finally understand it, thanks everyone
You mean that break; closed the file after open it? Actually what am i want to achieve is a simple things, but i don't know how to make it. 1. It...
Opps!:embarasse sorry about that, i don't where that things come from and i did not it notice.:disappoin
fopen is the code that return the pointer of a file structure, but i don't know very know how to return the pointer correctly that make the file...
You mean if the fopen successfully, it will open the file but if wrong it will do nothings?
I think every line that use to open the file fails, but i don't know the culprit. Its is better if this part can be fix: if(strcmp(op, "open")==...
After i edit the code, it become like this: #include <iostream> #include <fstream> #include <stdio.h> using namespace std; int main(int argc,...
I edit it : cin.ignore(); while (true) { cin >> op; if(strcmp(op, "open")== 0) fopen("g:\ccc\example.txt","r"); break;...
#include <iostream> #include <fstream> using namespace std; int main(int argc, char *argv[]) { int x ; char y[1000] ; char str[10];...
Separate names with a comma.