class Solution { public: void deleteNode(ListNode* node) { ListNode *p=node->next; node->val=p->val; node->next=p->next;//直接绕过去 delete p; } };