当前位置:网站首页>链表5 - 234. 回文链表
链表5 - 234. 回文链表
2022-06-23 11:39:00 【人工智能曾小健】

class Solution:
def isPalindrome(self,head:ListNode) -> bool:
vals= []
current_node =head
while current_node is not None:
vals.append(current_node.val)
current_node = current_node.next
return vals ==vals[::-1]class Solution:
def isPalindrome(self,head:ListNode) ->bool:
vals= []
current_node =head
while current_node is not None:
vals.append(current_node.val)
current_node = current_node.next
return vals ==vals[::-1]边栏推荐
- 语音数据标注工具与平台
- Monitor the cache update of Eureka client
- ESP32-C3入门教程 问题篇⑧——blufi_example.c:244: undefined reference to `esp_ble_gap_start_advertising
- Oversampling series I: sampling theorem and oversampling rate
- 【云驻共创】华为云HCIA-IoT V2.5培训系列内容之物联网概览
- Daily question 7-1652 Defuse the bomb
- Necessary software for automation or electrical specialty
- From 0 to 1, how does the IDE improve the efficiency of end-to-end R & D| DX R & D mode
- 全国进入主汛期,交通运输部:不具备安全运行条件的线路坚决停运!
- More than observation | Alibaba cloud observable suite officially released
猜你喜欢

PPT制作3D旋转动画从入门到进阶

quarkus+saas多租户动态数据源切换实现简单完美

Comment Huawei Cloud réalise l'architecture mondiale de réseau audio - vidéo en temps réel à faible latence

学习笔记 scrapy 爬虫框架

Introduction to redis - Chapter 1 - data structures and objects - simple dynamic string (SDS)

Leetcode 1209. 删除字符串中的所有相邻重复项 II(牛逼,终于过了)

汉源高科8路电话+1路百兆以太网RJ11电话光端机 8路PCM电话光端机

Meta said that the UK security law may "scan all private information" or infringe privacy

Redis 入门-第二篇-数据结构与对象-链表

六维图剖析:中国建筑集团有限公司企业成长性分析
随机推荐
Gary Marcus发文:AI研究者需要知道的三个来自语言学家的观点
公开课丨玩的就是短视频!今晚教你精准变现!
KDD 2022 | 基于分层图扩散学习的癫痫波预测
Introduction to redis - Chapter 1 - data structures and objects - simple dynamic string (SDS)
Introduction to Huawei cloud maintenance and sharing exchange platform
Oversampling series I: sampling theorem and oversampling rate
華為雲如何實現實時音視頻全球低時延網絡架構
过采样系列三:量化误差与过采样率
汉源高科1路千兆光口转4路千兆以太网电口千兆1光4电光纤收发器
单向链表实现--计数
一般的理财产品期限是几天啊?
惊!AMD 350亿美元收购赛灵思!
Groovy之范围
ESP32-C3入门教程 问题篇⑦—— fatal error: esp_bt.h: No such file or directory 找不到esp_bt.h
攻防演练合集 | 3个阶段,4大要点,蓝队防守全流程纲要解读
[cloud based co creation] overview of the IOT of Huawei cloud HCIA IOT v2.5 training series
@黑马粉丝,这份「高温补贴」你还没领?
At 14:00 today, 12 Chinese scholars started ICLR 2022
【云舟说直播间】-数字安全专场明天下午正式上线
Comment Huawei Cloud réalise l'architecture mondiale de réseau audio - vidéo en temps réel à faible latence