getline alternatives

Bit of an open-ended question I'm afraid.

I am learning C++ by following a book by Tony Jenkins. One of the exercises is to analyse a user input sequence of words, finding the number of words, characters, spaces, etc. in the input. The text input is to be finished with the word END (which is taken not to occur anywhere else in the string).

cin is the only user input method covered in the book, and having done some google research I could solve the problem using getline.

However, getline is not mentioned at all in the book. Is there another way around the problem? It is really annoying me, as the solution must be fairly simple (all the c++ used in the book so far is straightforward).

Thanks
Topic archived. No new replies allowed.