237. Delete Node in a Linked List
https://leetcode.com/problems/delete-node-in-a-linked-list/
Python
class Solution:
def deleteNode(self, node):
cur = node
while cur.next:
cur.val = cur.next.val
if not cur.next.next:
break
cur = cur.next
cur.next = None