I use C++. .I have a big problem. I need to divide data from the strings and put them into the vector.In this case, let's say i have two strings and each string will end with '\n', how will i read the characters for each string without ignoring the newline?
Example of strings
"3332 2223 2224 5443" //string 1 (entity a)
"6654 5522 3432 6754" //string 2 (entity b)
Each string is representing an entity for my problem. If i use ">>", this operator will ignores the newline of these strings, and it is not suitable for my problem. (Because i need to compare and sort the data based on the strings)
Can somebody gives some suggestions on what method or how should i deal with this problem?