I have a simple program that inputs data...I need a function that goes to the next line of code. So far i have tried ignore() and seekg() but I can't get it to correctly read the data from the text file from the next line.
I have a simple program that inputs data...I need a function that goes to the next line of code. So far i have tried ignore() and seekg() but I can't get it to correctly read the data from the text file from the next line.
a "line" is kind of a fake concept. it just means carriage return / linefeed (or just carriage return). there are of course ways that this has been done already for you (getline comes to mind) but you could just read each char until you get to the carriage return / line feed and then you'll know its the end of the line.
"You are stupid! You are stupid! Oh, and don't forget, you are STUPID!" - Dexter
well I used seeg('\n') and then ignore two spaces to get to the next line, and, it is working (I checked with real data)