C++|dummyNodes-Concept|Fast|EasyToUnderstand|O(n)|
On the Go find the sum and just insert at last of dummy node.\n2.  dummy\'s next will always point to the head of required node.\n\n```\n  class Solution {\npub
1. On the Go find the sum and just insert at last of dummy node.\n2.  dummy\'s next will always point to the head of required node.\n\n```\n  class Solution {\npublic:\n    ListNode* mergeNodes(ListNode* head) {\n         \n        ListNode *curr = head;\n        ListNode *second = NULL;\n        ListNode *dummy = new ListNode(0);\n        ListNode *tail = dummy;\n          \n        while(curr!=NULL && curr->next!=NULL){\n            second = curr->next;\n            int sum = 0;\n            \n            while(second->val != 0){\n                sum+=second->val;\n                second=second->next;\n            }\n            \n            ListNode *temp = new ListNode(sum);\n            tail->next = temp;\n            tail = temp;\n            \n            curr=second;   \n        }\n        \n        return dummy->next;\n    }\n};
['Linked List']