Chris Wellons personal blog
Solving “Two Sum” in C with a tiny hash table
I came across a question: How does one efficiently solve Two Sum in C? There’s a naive quadratic time solution, but also an amortized linear time solution using a hash table. Without a built-in or standard library hash table, the latter sounds onerous. However, a mask-step-index table , a hash table construction…
- Points
- 115
- HN comments
- 45
- Submissions
- 1
- Cited by
- 0 commenters
Software EngineeringMath & Algorithms2023
On Hacker News
| Submitted | Title on HN | Points | Comments |
|---|---|---|---|
| Jun 27, 2023 | Solving “Two Sum” in C with a tiny hash table by ingve | 115 | 45 |