problems with fstream

closed account (98qGz8AR)
hello everybody,
i've got an assignment at uni to make a program that echoes data from a file saved in a directory and then manipulates that data (multiplies and divides numbers from it specifically). i've got the entering the file path and echoing the data part down just fine, but i can't figure out how to pull specific numbers from the stream.
i have each different class of data declared in ifstream, but i can't figure it out from there. i've done a bunch of reading on it, and i think i need to use either get or getline, but i'm lost after that.
i can post code if that would help.
Get the data into the string, and then manipulate the string by means of find() and substr().

See:
http://www.cplusplus.com/reference/string/string/find/
http://www.cplusplus.com/reference/string/string/substr/
closed account (98qGz8AR)
thank you!
Topic archived. No new replies allowed.