data-structures · intermediate · ~15 min
Search an open-addressing table the way insertion laid it out.
With the same convention (0 = empty), implement int table_find(const int *table, int cap, int start, int key) returning the index where key is stored — probing forward from start — or -1 if an empty slot is hit first or the table is exhausted.
int table_find(const int *table, int cap, int start, int key) {
/* TODO */
return -1;
}
Solve this exercise in the browser editor — compile and run against the test harness, no setup required.