当前位置:网站首页>Leetcode-83 delete duplicate elements in the sorting linked list
Leetcode-83 delete duplicate elements in the sorting linked list
2022-07-01 18:47:00 【It was the sea】

class Solution(object):
def deleteDuplicates(self, head):
"""
:type head: ListNode
:rtype: ListNode
"""
if not head : return
cur = head
while cur.next:
if cur.val == cur.next.val:
cur.next = cur.next.next
else:
cur = cur.next
return head
边栏推荐
- 解决方案:可以ping别人,但是别人不能ping我
- 540. Single element in ordered array / 1684 Count the number of consistent strings
- Sum of three numbers
- 1380. Lucky number in matrix / 1672 Total assets of the richest customers
- 力扣每日一题-第32天-589.N×树的前序遍历
- On the language internationalization of Yongzhong Office
- R语言使用epiDisplay包的dotplot函数通过点图的形式可视化不同区间数据点的频率、使用pch参数自定义指定点图数据点的形状
- Bug of QQ browser article comment: the commentator is wrong
- How does factor analysis calculate weights?
- 6款红黄黑榜摄像头评测:谁最安全?谁画质好?从此让你不再踩雷
猜你喜欢
![[source code analysis] NVIDIA hugectr, GPU version parameter server - (1)](/img/92/f3a70e7086aeedf41eea3eef98b5aa.jpg)
[source code analysis] NVIDIA hugectr, GPU version parameter server - (1)

ACM MM 2022视频理解挑战赛视频分类赛道冠军AutoX团队技术分享

Technology implementation and Architecture Practice

Calculation of intersection of two line segments

How to manage 1000 anchors by one person?

Case study on comprehensive competitiveness of principal components

Vidéos courtes recommandées chaque semaine: méfiez - vous de la confusion entre « phénomène » et « problème »

Using OpenSSL encryption to rebound shell traffic

NSI packaging script add file details

创建您自己的NFT集合并发布一个Web3应用程序来展示它们(介绍)
随机推荐
解决方案:可以ping别人,但是别人不能ping我
Memo - about C # generating barcode
LeetCode 148. Sort linked list
宏观视角看抖音全生态
关于企业中台规划和 IT 架构微服务转型
R语言ggplot2可视化:gganimate创建动态柱状图动画(gif)、在动画中沿给定维度逐步显示柱状图、enter_grow函数和enter_fade函数控制运动内插退出(渐变tweening)
Lumiprobe 生物分子定量丨QuDye 蛋白定量试剂盒
R language uses the transmute function of dplyr package to calculate the moving window mean value of the specified data column in dataframe data, and uses ggplot2 package to visualize the line graph b
Vidéos courtes recommandées chaque semaine: méfiez - vous de la confusion entre « phénomène » et « problème »
[noip2015] jumping stone
Blue Bridge Cup real question: score statistics
Classpath classpath
12. Design of power divider for ads usage record
用WPF写一款开源方便、快捷的数据库文档查询、生成工具
Sanfeng cloud 0215 I often use
Implementation of converting PCM file to WAV
AI 训练速度突破摩尔定律;宋舒然团队获得RSS 2022最佳论文奖
力扣每日一题-第32天-1232. 缀点成线
About enterprise middle office planning and it architecture microservice transformation
What if the reliability coefficient is low? How to calculate the reliability coefficient?