码迷,mamicode.com
首页 >  
搜索关键字:linked_list    ( 3784个结果
【Leetcode】141. Linked List Cycle
Given a linked list, determine if it has a cycle in it. Follow up: Can you solve it without using extra space? Given a linked list, determine if it ha ...
分类:其他好文   时间:2018-02-20 10:32:42    阅读次数:124
Java实现单链表的快速排序和归并排序
本文描述了LeetCode 148题 "sort list" 的解法。 题目描述如下: Sort a linked list in O(n log n) time using constant space complexity. 题目要求我们在O(n log n)时间复杂度下完成对单链表的排序,我们 ...
分类:编程语言   时间:2018-02-18 17:03:33    阅读次数:201
【leetcode】Flatten Binary Tree to Linked List
分析: 问题是将给定的二叉树变换成令一种形式,这样的类型的问题。其模式是,将左子树变换成某种形式,右子树也变换成这样的形式,然后再与根结点按规定的方式连接起来,那么总体就变换完毕了。这个题我们就能够採用这样的形式。麻烦的地方就是在进行连接的时候。我们如果根为root,左子树变换后的根为root_le ...
分类:其他好文   时间:2018-02-17 11:49:26    阅读次数:193
【Leetcode】237. Delete Node in a Linked List
Write a function to delete a node (except the tail) in a singly linked list, given only access to that node. Supposed the linked list is 1 -> 2 -> 3 - ...
分类:其他好文   时间:2018-02-14 23:39:23    阅读次数:312
Remove Duplicates from Sorted List II
题目描写叙述 链接地址 解法 题目描写叙述 Given a sorted linked list, delete all nodes that have duplicate numbers, leaving only distinct numbers from the original list. ...
分类:其他好文   时间:2018-02-14 18:42:58    阅读次数:144
[leetcode]203. Remove Linked List Elements链表中删除节点
这道题很基础也很重要 重点就是设置超前节点 ...
分类:其他好文   时间:2018-02-13 12:25:53    阅读次数:141
【easy】141. Linked List Cycle
非常简单的题:判断链表有没有环(用快慢指针) ...
分类:其他好文   时间:2018-02-12 23:38:05    阅读次数:204
25.leetcode142_linked_list_cycle_II
1.题目描述 Given a linked list, return the node where the cycle begins. If there is no cycle, return null. Note: Do not modify the linked list. 给出一个链表,返回链 ...
分类:其他好文   时间:2018-02-12 22:22:58    阅读次数:202
PAT 1052. Linked List Sorting (25)
1052. Linked List Sorting (25) 时间限制 400 ms 内存限制 65536 kB 代码长度限制 16000 B 判题程序 Standard 作者 CHEN, Yue 时间限制 400 ms 时间限制 400 ms 内存限制 65536 kB 内存限制 65536 kB ...
分类:其他好文   时间:2018-02-12 00:20:11    阅读次数:228
[leetcode]725. Split Linked List in Parts链表分块
思路很简单 按时链表的题做起来很容易犯小错误,思维要缜密 还要多练习啊 做之前最好画算法框图 ...
分类:其他好文   时间:2018-02-11 21:24:00    阅读次数:231
3784条   上一页 1 ... 76 77 78 79 80 ... 379 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!