Hi everybody!
I was trying to do some linked lists exercises, and I'd like to ask you what is the difference between the following two prototypes?
Is one of this wrong? The meaning is the same or the second one means that sPtr is a pointer to a second pointer?Code:void insert(ListNodePtr sPtr, char value); void insert(ListNodePtr *sPtr, char value);
These were the definitions of the linked list components:
Code:typedef struct listNode ListNode; typedef ListNode *ListNodePtr; struct listNode { char data; ListNodePtr nextPtr; };
Thanks,
Diego



LinkBack URL
About LinkBacks




