Beginner here so please bear with me. So I am reading data from a csv file and I need to read data word by word and stop at the end of the line. This is the code.
fstream fops;
fops.open("file.csv");
string s;
do
{
fops>>s;
}while(s!="\n");
However the loop continues to the next line until the file ends. Please help me out on this