Merge two sorted linked lists and return it as a new list.
The new list should be made by splicing together the nodes of the first two lists.
Solution: Make a temp node to point to the head pointer of result.
Then we put each element into the list and return the head of the pointer at last.
0 意見:
張貼留言