LeetCode-83-Remove Duplicates from Sorted List 链表水题
来源:互联网 发布:淘宝直播入口在哪 编辑:程序博客网 时间:2024/05/17 16:12
# Definition for singly-linked list.# class ListNode(object):# def __init__(self, x):# self.val = x# self.next = Noneclass Solution(object): def deleteDuplicates(self, head): """ :type head: ListNode :rtype: ListNode """ if head==None:return None ans=head while(head.next!=None): if head.next.val==head.val: head.next=head.next.next else: head=head.next return ans
阅读全文
1 0
- LeetCode(83)Remove Duplicates from Sorted List
- [leetcode 83]Remove Duplicates from Sorted List
- [leetcode]83 Remove Duplicates from Sorted List
- [leetcode 83]Remove Duplicates from Sorted List
- leetcode-83 Remove Duplicates from Sorted List
- leetcode || 83、Remove Duplicates from Sorted List
- LeetCode 83 Remove Duplicates from Sorted List
- LeetCode---(83) Remove Duplicates from Sorted List
- leetcode 83 Remove Duplicates from Sorted List
- LeetCode 83:Remove Duplicates from Sorted List
- leetcode[83]:Remove Duplicates from Sorted List
- Leetcode[83]-Remove Duplicates from Sorted List
- Leetcode #83 Remove Duplicates from Sorted List
- leetcode 83: Remove Duplicates from Sorted List
- leetcode: (83) Remove Duplicates from Sorted List
- [Leetcode]#83 Remove Duplicates from Sorted List
- LeetCode 83 - Remove Duplicates from Sorted List
- [LeetCode-83] Remove Duplicates from Sorted List
- matlib与excel交互
- POJ_3468 A Simple Problem with Integers(线段树区间修改+附线段树模板)
- electron打包
- poj 3013 Big Christmas Tree 最短路 (转换思维,看点不看边)
- maven用变量的方法统一管理jar包版本
- LeetCode-83-Remove Duplicates from Sorted List 链表水题
- 马踏棋盘
- java远程连接数据库
- C语言实验——三个整数和、积与平均值
- 飙车
- Servlet之Filter过滤器
- Unable to locate package apache2
- 机器学习的学习路线
- 假期有时间写代码:FireMonkey 之多语言(TLang)