title: C++ read from file only when there is more content
body: <p>How can I check if there is more content in a text file in c++ and if there is continue to read it?
  I am trying to read a some words from a text file but the number of words is not specified.</p>