A
aTuL
Hi All,
I am trying to open a ~720 Megs of file and print it. the code looks
like this.
ifstream ratingFile(strFileName.c_str());
if(!ratingFile.is_open()){
cout<<"Error: input file for ratings could not be opened.
Quitting\n"<<endl;
exit(GENERIC_ERROR);
}
while(!ratingFile.eof()){
//string strRatingline;
char strRatingline[20000];
cin>>strRatingline;
cout<<strRatingline;
}
When I run the code it just hangs at cin statement for really long.
Now what that makes me think is is my code wrong or something or it is
just reading all of the data and then plans to fill in my string?
I am trying to open a ~720 Megs of file and print it. the code looks
like this.
ifstream ratingFile(strFileName.c_str());
if(!ratingFile.is_open()){
cout<<"Error: input file for ratings could not be opened.
Quitting\n"<<endl;
exit(GENERIC_ERROR);
}
while(!ratingFile.eof()){
//string strRatingline;
char strRatingline[20000];
cin>>strRatingline;
cout<<strRatingline;
}
When I run the code it just hangs at cin statement for really long.
Now what that makes me think is is my code wrong or something or it is
just reading all of the data and then plans to fill in my string?