Lightweight hash set class for storing ints Simple hash table with quadratic probing.
More...
#include <IntSet.h>
List of all members.
Detailed Description
Lightweight hash set class for storing ints Simple hash table with quadratic probing.
Constructor & Destructor Documentation
IntSet::IntSet
|
( |
int
|
capacity
) |
|
- Parameters:
-
[in] | capacity | Initial maximum size of hash set |
Member Function Documentation
bool IntSet::find
|
( |
int
|
x
) |
|
returns whether x is in hash table
- Returns:
- whether x is in hash table
returns the number of elements stored in hash table
- Returns:
- the number of elements stored in hash table
bool IntSet::insert
|
( |
int
|
x
) |
|
inserts x into hash table, returns whether x was inserted
- Parameters:
-
[in] | x | value to insert into set |
- Returns:
- whether x was successfully inserted. If x is already in table, returns false
The documentation for this class was generated from the following files: