How to store set of long char strings to search for long char string key I have a set of several thousand strings of max length 1024 (containing all visible ASCII chars plus space) I need to store to make it fast to search for an exact match of a key.  What is the best algorithm to store the set and to search for a match?
One approach is to use a suffix array (or suffix tree).  That allows very fast searching for a match.

Given multiple words, there is a standard way to compute a suffix array (or suffix tree) associated with them: concatenate them, separated by some separator.  For instance, if the words are APPLE, CAT, and DOG, you obtain the string APPLE\$CAT\$DOG\$.  Then, compute the suffix array/tree of that single long string.