摘要: https://leetcode-cn.com/problems/reverse-linked-list/ 1.题目描述 给你单链表的头节点 head ,请你反转链表,并返回反转后的链表 2.思路 用二个指针,pre指向反转链表的首结点,curr指向链表的首结点,每次将curr->next指向pre 阅读全文
posted @ 2021-07-14 13:57 liushz 阅读(35) 评论(0) 推荐(0)