I have given a function foo(struct node *n) where n is the head node in a linked list.
Now foo should change n s.t. it points to the end of the list.
But is this possible with this function signature?
Assuming t is the pointer to the end of the list:
n = twon't work because the pointer is passed by value.*n = *twon't work because I would overwrite the head of the list.
Did I miss something?