I have never used a trie, so I may be wrong, but I don't think this is a good example of when to use them. As I understand, a trie is good for when you have a lot of strings and you expect to do a lot of looking up, not to pack them all in, use one, and then destroy it. I think that defeats the purpose, unless I'm reading this wrong.
In this case, we're not actually searching for a string, we just want any of them.
Edit: Heh, couldn't we just use
PHP Code:
random(file_size("file",1))
and read that one line?
I think we're being a little overcomplicated.
__________________