- Singly-linked List(Easy)
- 237. Delete Node in a Linked Lis
- 237. Delete Node in a Linked Lis
- 237. Delete Node in a Linked Lis
- 237. Delete Node in a Linked Lis
- 237. Delete Node in a Linked Lis
- 237. Delete Node in a Linked Lis
- 237. Delete Node in a Linked Lis
- 237. Delete Node in a Linked Lis
- 237. Delete Node in a Linked Lis
https://leetcode.com/problems/delete-node-in-a-linked-list/description/
class Solution {
public void deleteNode(ListNode node) {
node.val = node.next.val;
node.next = node.next.next;
}
}
网友评论