-
Spell checking program
Hi,
I'm looking to implement a very simple spell checker program that takes a text file as input and identifies any words not in its dictionary. The dictionary is itself a text file containing a list of words. Any word not found in the dictionary is considered wrong and the user should be asked to suggest an alternative or leave the word as it is.
I've been recommended to read the dictionary file into either binary search array or a hash table (I don't know which one would be more efficient).
I have absolutely minimal experience in C, so if anyone could help me out with this I'd very much appreciate it.
Many thanks,
Johnny
-
The method in which to implement it solely depends on what you are doing. Are you asking the user for a word, are you making a text editor, ...?
-
The user inputs a text file to be checked for spelling. Any words in that text file that don't match a word in the dictionary text file are wrong. The user can change the wrong words to create an output file.
I hope this makes it more clear.
Thanks.
-
Sounds like a sorted array (for binary search) will do.