0x0
0x0

Reputation: 3075

Program to create a hash table

I want to read an array of integers, hash each integer and put it into an hash table and later lookup the table to search for the value. What would be the efficient way to do that in c/c++? Thanks in advance

Upvotes: 1

Views: 878

Answers (1)

James McNellis
James McNellis

Reputation: 355079

If your compiler supports it, you can use std::unordered_set. If your compiler doesn't support that yet, most implementations support hash_set (which is well documented in the SGI STL documentation).

Upvotes: 4

Related Questions