i am working on a text twist like program on visual studio 2008 c++ or devc++ and i'm trying to figure out how would i access the list of words from a text file line by line or maybe convert it into an array so that i can access it by array[number] form
text file looks like this
ant
bag
can
dip
eat
fog
etc
|
dictionary word list composed of 3, 4, 5, 6 and 7-letter words
so its a big file if i manually put it into an array
i just want to access it per line for word comparison
____
i already made an anagram and code with very few words stored in an array and try working the program and it worked!
now my wish is how to access the word list text file?
i cant make it like this
string Word_list[]={"bag",
"can",
"dip",
"eat",
",fog",
"etc"}; |
the list of words contains tens of thousands of words!=)
any help would be greatly appreciated...