I don't know what happend to the post I thought I made to you about this quite a while back, but basically this:
Code:
hockey_player* p_1_front = NULL;//ptr to the itms in each bucket(ie. the address in each arr indx to a list)
hockey_player* p_2_front = NULL;
hockey_player* p_3_front = NULL;
hockey_player* p_4_front = NULL;
hockey_player* p_5_front = NULL;
hockey_player* p_6_front = NULL;
hockey_player* p_7_front = NULL;
hockey_player* p_8_front = NULL;
hockey_player* p_9_front = NULL;
hockey_player* p_10_front = NULL;
hockey_player* bucket[10] = {p_1_front, p_2_front, p_3_front, p_4_front, p_5_front, p_6_front, p_7_front,
p_8_front, p_9_front};
Is the same as just doing:
Code:
hockey_player* bucket[10] = {NULL};
You set 10 individual pointers to NULL, and then copy all those NULLs into your array pointers. Congratulations, you now have a very long winded way of initialising the array to all NULLs.
There exists therafter, no link whatsoever between the array and those individual variables.