E-COM-NET
首页
在线工具
Layui镜像站
SUI文档
联系我们
推荐频道
Java
PHP
C++
C
C#
Python
Ruby
go语言
Scala
Servlet
Vue
MySQL
NoSQL
Redis
CSS
Oracle
SQL Server
DB2
HBase
Http
HTML5
Spring
Ajax
Jquery
JavaScript
Json
XML
NodeJs
mybatis
Hibernate
算法
设计模式
shell
数据结构
大数据
JS
消息中间件
正则表达式
Tomcat
SQL
Nginx
Shiro
Maven
Linux
Singly
Merge k Sorted Lists
. /* * * Definition for
singly
-linked list. * struct&nb
·
2015-11-11 18:06
merge
Convert Sorted List to Binary Search Tree
Given a
singly
linked list where elements are sorted in ascending order, convert it to a height balanced
·
2015-11-11 18:38
search
binary
[LeetCode OJ] Reorder List—Given a
singly
linked list L: L0→L1→…→Ln-1→Ln, reorder it to: L0→Ln→L1→Ln-
For example,Given {1,2,3,4}, reorder it to {1,4,2,3}. 1 /** 2 * Definition for
singly
-linked
·
2015-11-11 18:43
LeetCode
[LeetCode OJ] Linked List Cycle II—Given a linked list, return the node where the cycle begins. If there is no cycle, return null.
1 /** 2 * Definition for
singly
-linked list. 3 * struct ListNode { 4 * int val; 5 *
·
2015-11-11 18:43
LeetCode
逆序访问单链表
This is a simple but important algorithm when dealing with
singly
linked list.
·
2015-11-11 17:57
单链表
PAT 1074. Reversing Linked List (25)
Given a constant K and a
singly
linked list L, you are supposed to reverse the links of every K elements
·
2015-11-11 16:04
list
Convert Sorted List to Binary Search Tree
Given a
singly
linked list where elements are sorted in ascending order, convert it to a height balanced
·
2015-11-11 16:56
search
binary
Reorder List
Given a
singly
linked list L: L0→L1→…→Ln-1→Ln,reorder it to: L0→Ln→L1→Ln-1→L2→Ln-2→…
·
2015-11-11 15:36
order
Insertion Sort List
Sort a linked list using insertion sort. 1 /** 2 * Definition for
singly
-linked list. 3 * public
·
2015-11-11 15:08
insert
Merge Two Sorted Lists
1 /** 2 * Definition for
singly
-linked list.
·
2015-11-11 15:59
merge
Sort List
. /** * Definition for
singly
-linked list.
·
2015-11-11 13:42
list
Insertion Sort List
. /** * Definition for
singly
-linked list.
·
2015-11-11 13:41
insert
Reorder List
Given a
singly
linked list L: L0→L1→…→Ln-1→Ln,reorder it to: L0→Ln→L1→Ln-1→L2→Ln-2→…
·
2015-11-11 13:38
order
Linked List Cycle II
/** * Definition for
singly
-linked list.
·
2015-11-11 13:37
list
Linked List Cycle
/** * Definition for
singly
-linked list. * struct ListNode { * int val; *
·
2015-11-11 13:37
list
Copy List with Random Pointer
. /** * Definition for
singly
-lin
·
2015-11-11 13:35
Random
Convert Sorted List to Binary Search Tree
Given a
singly
linked list where elements are sorted in ascending order, convert it to a height balanced
·
2015-11-11 13:14
Binary search
Leetcode: Intersection of Two Linked Lists
Write a program to find the node at which the intersection of two
singly
linked lists begins.
·
2015-11-11 12:05
intersect
Leetcode: Reorder List && Summary: Reverse a LinkedList
Given a
singly
linked list L: L0→L1→…→Ln-1→Ln, reorder it to: L0→Ln→L1→Ln-1→L2→Ln-2→… You must do
·
2015-11-11 12:40
LinkedList
Leetcode: Linked List Cycle
一次过 1 /** 2 * Definition for
singly
-linke
·
2015-11-11 12:29
LeetCode
Intersection of Two Linked Lists
Write a program to find the node at which the intersection of two
singly
linked lists begins.
·
2015-11-11 11:34
intersect
【面试题】重排单链表
Given a
singly
linked list L: (L0 , L1 , L2...Ln-1 , Ln).
·
2015-11-11 10:37
面试题
[cc150] check palindrome of a
singly
linked list
Problem: Implement a function to check if a
singly
linked list is a palindrome.
·
2015-11-11 07:36
check
Detect loop in a
singly
linked list
去Twitter面试的被问到这个问题,当时只想到了用HashMap的办法,这种办法时间复杂度O(n),空间复杂度是O(n), 更好的办法是用 FastRunner / SlowRunner approach。用两个pointer遍历链表,fast的速度是slow的两倍,如果有loop,二者一定会collide。 boolean detectLoop(LinkedListNode head){
·
2015-11-11 07:35
list
Add Two Numbers
代码: /** * Definition for
singly
-linked list.
·
2015-11-11 06:30
number
Reverse Linked List
Reverse a
singly
linked list. click to show more hints.
·
2015-11-11 04:02
list
求两个单链表的和
作者:Hawstein 出处:http://hawstein.com/posts/add-
singly
-linked-list.html 题目 两个单链表(
singly
·
2015-11-11 04:04
单链表
sys/queue.h
包括
singly
-lined list, list, simple queue(
Singly
-linked Tail queue), tail queue, circle queue五种。
·
2015-11-11 03:24
Queue
Sort List ——LeetCode
/** * Definition for
singly
-linked list. * public class ListNode { *
·
2015-11-11 01:53
LeetCode
Insertion Sort List —— LeetCode
/** * Definition for
singly
-linked list. * public class ListNode { *
·
2015-11-11 01:46
LeetCode
Leetcode: Convert Sorted List to Binary Search Tree
Given a
singly
linked list where elements are sorted in ascending order, convert it to a height balanced
·
2015-11-11 01:51
Binary search
[leetcode]Linked List Cycle II
/** * Definition for
singly
-linked list. * struct ListNode { *
·
2015-11-10 21:06
LeetCode
[leetcode]Linked List Cycle
/** * Definition for
singly
-linked list.
·
2015-11-10 21:05
LeetCode
LeetCode Convert Sorted List to Binary Search Tree
/** * Definition for
singly
-linked list.
·
2015-11-09 14:41
Binary search
LeetCode Partition List
/** * Definition for
singly
-linked list.
·
2015-11-09 14:37
partition
【LeetCode】160. Intersection of Two Linked Lists
Intersection of Two Linked Lists Write a program to find the node at which the intersection of two
singly
·
2015-11-09 13:57
intersect
Add Two Numbers
/** * Definition for
singly
-linked list.
·
2015-11-09 12:20
number
HappyLeetcode42:Intersection of Two Linked Lists
Write a program to find the node at which the intersection of two
singly
linked lists begins.
·
2015-11-09 12:59
intersect
Convert Sorted List to Binary Search Tree
https://oj.leetcode.com/problems/convert-sorted-list-to-binary-search-tree/ Given a
singly
linked list
·
2015-11-09 11:14
Binary search
Lintcode: Nth to Last Node in List
Find the nth to last element of a
singly
linked list.
·
2015-11-08 17:07
list
Leetcode OJ : Merge k Sorted Lists 归并排序+最小堆 mergesort heap C++ solution
1 /** 2 * Definition for
singly
-linked list. 3 * struct ListNode { 4 * int val; 5 *
·
2015-11-08 16:29
mergesort
Sort list by merge sort
使用归并排序对链表进行排序 O(nlgn) 的时间效率 /** * Definition for
singly
-linked list.
·
2015-11-08 15:44
merge
3月3日(4) Remove Duplicates from Sorted List
/** * Definition for
singly
-linked list.
·
2015-11-08 14:05
remove
Leetcode Intersection of Two Linked Lists
/** * Definition for
singly
-linked list.
·
2015-11-08 12:35
intersect
LeetCode Linked List Cycle
/** * Definition for
singly
-linked list.
·
2015-11-08 12:11
LeetCode
LeetCode Linked List Cycle II
/** * Definition for
singly
-linked list.
·
2015-11-08 12:08
LeetCode
两个有序链表连接(归并排序中用到的)
刚才写了k个,顺手写个2个的,在链表的归并排序中很有用,效率非常好 1 /** 2 * Definition for
singly
-linked list. 3 * public
·
2015-11-08 11:16
归并排序
(java) Merge k sorted linked lists and return it as one sorted list. Analyze and describe its complexity.
1 /** 2 * Definition for
singly
-linked list. 3 * public class ListNode { 4 * int val;
·
2015-11-08 11:15
return
【LeetCode】143. Reorder List
Reorder List Given a
singly
linked list L: L0→L1→…→Ln-1→Ln,reorder it to: L0→Ln→L1→Ln
·
2015-11-08 11:38
LeetCode
【LeetCode】109. Convert Sorted List to Binary Search Tree
Convert Sorted List to Binary Search Tree Given a
singly
linked list where elements are sorted in ascending
·
2015-11-08 11:38
search
binary
上一页
1
2
3
4
5
6
7
8
下一页
按字母分类:
A
B
C
D
E
F
G
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
Z
其他