Huge vector, find item fast

Hello, this is my first post. I've been searching the net but haven't found a good answer.

I want to build a server which holds hunders of thousands of active users in memory. To keep all the users organized i would like to store them in a Vector (or something better suggested?).

The problem is how i could quicky and easy find the object whenever i need it? All users will have a unique ID. Would it be possible to keep some form of a Vector Index on the unique id number?

Thank you for your time.
Thank you, that's perfect.
Topic archived. No new replies allowed.