You could use a hash table to store a large buffer of lines.


http://scripting.pball.win
My personal site with some scripts I've released.