mycode

# Definition for singly-linked list.
# class ListNode(object):
#     def __init__(self, x):
#         self.val = x
#         self.next = None

class Solution(object):
    def deleteNode(self, node):
        """
        :type node: ListNode
        :rtype: void Do not return anything, modify node in-place instead.
        """
        node.val = node.next.val
        node.next = node.next.next
        

 

相关文章:

  • 2021-07-19
  • 2022-01-03
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-09-07
  • 2021-07-13
猜你喜欢
  • 2021-12-06
  • 2021-06-22
  • 2021-11-27
  • 2021-12-03
  • 2022-02-10
  • 2021-12-27
相关资源
相似解决方案