Hello everyone! I'm stuck over something for a project, and this is actually the last part >_>
Here's the string of code;
fstream my_file_1;
T="";
string file = "chr1.fa";
my_file_1.open(file.c_str());
getline(my_file_1,T);
while (!my_file_1.eof())
getline(my_file_1,T);
my_file_1.close();
cout<<T<<endl<<T.size()<<endl;
For some reason, whenever I run at the end the result of T is an empty string.
Does anybody happen to see where my error lies?
Last edited on