help with creating a hash table

I'm writing a program that find solutions to the 8-puzzle game

I need to make a hash table that has 2 operations

member(node *) which takes a pointer to a node and determines if the board in the node is equal

// member method to see if a value is in the table

// I'm not sure how to adapy this code

int hashtable::HLookup(int value){

// get the index

int index = hash(value);

// get the location in the table

node *p = table[index];

// p is the head of a linked list, so now we need to

//scan the link list to find the value

int found = 0;

while(p != NULL)

{

countHash++;

// see if the current element matches

if(p->value == value)

{

found = true;

break;

}

// go to next element

else p = p->next;

}

return found;

}

insert (node *) which puts a new node in the hash table

// insert method

//not sure how to use a pointer here

void hashtable::HInsert (int value){

node *p = table [hash(value)];

if (p==NULL){

countHash++;

table [hash(value)] = new node;

table [hash (value)]->value = value;

}

else {

while (p->next !=NULL){

p = p->next;

countHash++;

}

p->next = new node;

}

}