Fastest way to check if a List<String> contains a unique String

Viewed 72664

Basically I have about 1,000,000 strings, for each request I have to check if a String belongs to the list or not.

I'm worried about the performance, so what's the best method? ArrayList? Hash?

10 Answers
Related