Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rishabh672003/hash-table-in-cpp
A very simple hash table implementation in CPP
https://github.com/rishabh672003/hash-table-in-cpp
cmake cpp cpp20 data-structures hash hash-table hashing
Last synced: 2 months ago
JSON representation
A very simple hash table implementation in CPP
- Host: GitHub
- URL: https://github.com/rishabh672003/hash-table-in-cpp
- Owner: Rishabh672003
- License: gpl-3.0
- Created: 2023-12-16T10:14:26.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2024-01-01T07:34:56.000Z (about 1 year ago)
- Last Synced: 2024-10-11T22:51:10.907Z (3 months ago)
- Topics: cmake, cpp, cpp20, data-structures, hash, hash-table, hashing
- Language: C++
- Homepage:
- Size: 38.1 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Hash-Table-in-CPP
A very simple hash table implementation in CPP,
## Very simple API
```cpp
ht_hash_table hash_table;
hash_table.insert("hello", "world");
hash_table.insert("hi", "Rishabh");
print("{}\n", hash_table.search("hi"));
hash_table.remove("hi");
```Written in modern CPP so no memory leaks, checked using Valgrind
![image](https://github.com/Rishabh672003/Hash-Table-in-CPP/assets/53911515/306b7c0c-2dcb-4f17-abf0-9beae48aab9b)## Credit
I wrote this while following [How to write a Hash Table](https://github.com/jamesroutley/write-a-hash-table).
it was written in C so for learning purpose I converted it to CPP, logic is same but i have changed the implementation
to an OOPS one, with classes and other modern CPP features like using standard string and others