After exhaustive googling and visiting many forums, I am yet to find a good comprehensive answer for this question. A lot of the forums suggest using the get line
istream& getline (char* s, streamsize n )
function. My question is what if I don't know what the length of each line is and cannot predict what the size may be? Also what is it's equivalent in C?
Is there any specific function in c /c++ to read one single line each time from a text file ?
Explanation , with Code snippets will help me a lot.