in reply to Re^2: finding a set of relevant keys
in thread finding a set of relevant keys

ericleasemorgan,
To be honest, changing %words to a more appropriate data structure would probably be best. This way you could walk the tree. Unfortunately, without knowing how %words is used by the rest of the program or how it is maintained, that is a blind recommendation.

Cheers - L~R