What is the difference between Node *head versus Node **head?
问题 I am writing a C code to find the middle of linked list. I understood the logic but was unable to figure out how pointers are being used. What is the difference in the way Node *head and Node** head_ref work? void middle(struct Node *head) ; void push(struct Node** head_ref, int new_data) ; 回答1: In the first function header, *head is a pointer to a node object which is allocated somewhere in memory: void middle(struct Node *head); _____________________ | | *head --> | Node object | | [val=1][