摘要: Given the head of a sorted linked list, delete all nodes that have duplicate numbers, leaving only distinct numbers from the original list. Return the 阅读全文
posted @ 2019-11-08 03:24 CNoodle 阅读(453) 评论(0) 推荐(0)
摘要: Given the head of a sorted linked list, delete all duplicates such that each element appears only once. Return the linked list sorted as well. Example 阅读全文
posted @ 2019-11-08 01:40 CNoodle 阅读(441) 评论(0) 推荐(0)
摘要: Given the head of a linked list, remove the nth node from the end of the list and return its head. Example 1: Input: head = [1,2,3,4,5], n = 2 Output: 阅读全文
posted @ 2019-11-08 01:20 CNoodle 阅读(428) 评论(0) 推荐(0)