something like this: note, we are not going to write the program for you.
open the file
do this until end-of-file is reached
use extraction operator >> to read a word
check each character and remove any non-alphabetic characters
(hint: isalpha() macro will help you do make that check)
add the word to a std::string object
end of while loop
Ancient Dragon
Retired & Loving It
30,049 posts since Aug 2005
Reputation Points: 5,662
Solved Threads: 2,343