Data Structures and Algorithms
with Object-Oriented Design Patterns in C# |
To check the spelling in a given document, we hash the words in the document one-by-one and examine the corresponding bit of the array. If the bit is a zero, the word does not appear in the dictionary and we conclude that it is misspelled. Note if the bit is a one, the word may still be misspelled, but we cannot tell.
Design and implement a spelling checker. Hint: Use the SetAsBitVector class given in Chapter .