PREV INDEX NEXT

Author: Unknown
Subject: Return from search function
Date: Wednesday, 15 Apr 2020, 17:49:06

What exactly should our search function in our Hash module return? Are we allowed to have two different search functions in this module that return different things? In other words, are we allowed to more than just one search, one insert, one create, and possible one destroy function inside of our hash module? 

Given our header file is not supposed to specify the components of our struct, my understanding is that our search function cannot return the struct triplet itself. However, in the pseudocode given to us, we are supposed to figure out both NSTEPS of a key from the search function, 

(let N be the number of moves associated with P in the search table)

and REACHED_FROM of a key from the search function

(use the search table to print the sequence of positions & exit). 

How is it possible to do both those things from the same search function?
PREV INDEX NEXT