@isaacjumac . So, result contains the head of the returning linkedlist right? What I don't understand is How can result point to the very first element of the linked list? result = new ListNode(0). so, result.val = 0 and result.next = null. Would you please help me to clarify my mistake. thanks