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
LeetCode练习
【
LeetCode练习
题】Gas Station
Gas Station There are N gas stations along a circular route, where the amount of gas at station i is gas[i]. You have a car with an unlimited gas tank and it costs&n
·
2015-11-12 11:06
LeetCode
【
LeetCode练习
题】Merge Sorted Array
Merge Sorted Array Given two sorted integer arrays A and B, merge B into A as one sorted array. Note:You may assume that A has enough space (size that is greater or equal to m +&nb
·
2015-11-12 11:04
LeetCode
【
LeetCode练习
题】First Missing Positive
First Missing Positive Given an unsorted integer array, find the first missing positive integer. For example,Given [1,2,0] return 3,and [3,4,-1,1] return 2. Y
·
2015-11-12 11:04
LeetCode
【
LeetCode练习
题】Reverse Linked List II
Reverse Linked List II Reverse a linked list from position m to n. Do it in-place and in one-pass. For example:Given 1->2->3->4->5->NULL, m = 2 a
·
2015-11-12 11:03
LeetCode
【
LeetCode练习
题】Multiply Strings
Multiply Strings Given two numbers represented as strings, return multiplication of the numbers as a string. Note: The numbers can be arbitrarily large and are non-negative.
·
2015-11-12 11:02
LeetCode
【
LeetCode练习
题】Evaluate Reverse Polish Notation
Evaluate Reverse Polish Notation Evaluate the value of an arithmetic expression in Reverse Polish Notation. Valid operators are +, -, *, /. Each operand may be an in
·
2015-11-12 11:01
LeetCode
【
LeetCode练习
题】Merge k Sorted Lists
Merge k Sorted Lists Merge k sorted linked lists and return it as one sorted list. Analyze and describe its complexity. 题目意思: 合并K条已经排序的链表。分析时间复杂度。 解题思路: 很
·
2015-11-12 11:00
LeetCode
【
LeetCode练习
题】Next Permutation
Next Permutation Implement next permutation, which rearranges numbers into the lexicographically next greater permutation of numbers. If such arrangement is not possible, it must rearrange i
·
2015-11-12 11:59
LeetCode
【
LeetCode练习
题】Climbing Stairs
Climbing Stairs You are climbing a stair case. It takes n steps to reach to the top. Each time you can either climb 1 or 2 steps. In how many distinct ways can you climb to the top
·
2015-11-12 11:58
LeetCode
【
LeetCode练习
题】Validate Binary Search Tree
Validate Binary Search Tree Given a binary tree, determine if it is a valid binary search tree (BST). Assume a BST is defined as follows: The left subtree of a node contains only nodes
·
2015-11-12 11:57
Binary search
【
LeetCode练习
题】Remove Duplicates from Sorted List II
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. For example,Gi
·
2015-11-12 11:57
LeetCode
【
LeetCode练习
题】Copy List with Random Pointer
Copy List with Random Pointer A linked list is given such that each node contains an additional random pointer which could point to any node in the list or null. Return a deep copy of the li
·
2015-11-12 11:56
LeetCode
【
LeetCode练习
题】Add Two Numbers
链表相加 You are given two linked lists representing two non-negative numbers. The digits are stored in reverse order and each of their nodes contain a single digit. Add the two numbers and return it
·
2015-11-12 11:55
LeetCode
【
LeetCode练习
题】Permutations
全排列 Given a collection of numbers, return all possible permutations. For example,[1,2,3] have the following permutations:[1,2,3], [1,3,2], [2,1,3], [2,3,1], [3,1,2], and
·
2015-11-12 11:55
LeetCode
【
LeetCode练习
题】Candy
分糖果 There are N children standing in a line. Each child is assigned a rating value. You are giving candies to these children subjected to the following requirements: Each child m
·
2015-11-12 11:53
LeetCode
【
LeetCode练习
题】Partition List
Given a linked list and a value x, partition it such that all nodes less than x come before nodes greater than or equal to x. You should preserve the original relativ
·
2015-11-12 11:52
partition
【
LeetCode练习
题】Minimum Window Substring
找出包含子串的最小窗口 Given a string S and a string T, find the minimum window in S which will contain all the characters in T in complexity O(n). For example,S = "ADOBECODEBANC"T 
·
2015-11-12 11:52
substring
【
LeetCode练习
题】Pow(x, n)
Pow(x, n) Implement pow(x, n). 计算x的n次方。 解题思路: 考虑到n的值会很大,而且可为正可为负可为0,所以掉渣天的方法就是用递归了。 对了,这题也在《剑指offer》里面有提到,是面试题11:数值的整数次方。可以书里给的递归代码在n为负数的情况下是错误的……他没有考虑到n为奇数时,n
·
2015-11-11 17:51
LeetCode
【
LeetCode练习
题】Combination Sum
Combination Sum Given a set of candidate numbers (C) and a target number (T), find all unique combinations in C where the candidate numbers sums to T. The same repea
·
2015-11-11 17:50
LeetCode
【
LeetCode练习
题】Maximum Depth of Binary Tree
Maximum Depth of Binary Tree Given a binary tree, find its maximum depth. The maximum depth is the number of nodes along the longest path from the root node down to the farthest leaf node.
·
2015-11-11 17:49
LeetCode
【
LeetCode练习
题】Minimum Depth of Binary Tree
Minimum Depth of Binary Tree Given a binary tree, find its minimum depth. The minimum depth is the number of nodes along the shortest path from the root node down to the nearest leaf node.
·
2015-11-11 17:49
LeetCode
【
LeetCode练习
题】Reverse Words in a String
Reverse Words in a String Given an input string, reverse the string word by word. For example,Given s = "the sky is blue",return "blue is sky the". Clarification:
·
2015-11-11 17:48
LeetCode
【
LeetCode练习
题】Minimum Path Sum
Minimum Path Sum Given a m x n grid filled with non-negative numbers, find a path from top left to bottom right which minimizes the sum of all numbers along its p
·
2015-11-11 17:47
LeetCode
【
LeetCode练习
题】Swap Nodes in Pairs
Swap Nodes in Pairs Given a linked list, swap every two adjacent nodes and return its head. For example,Given 1->2->3->4, you should return the list as 2->1->4->3
·
2015-11-11 17:46
LeetCode
【
LeetCode练习
题】Unique Paths II
Unique Paths II Follow up for "Unique Paths": Now consider if some obstacles are added to the grids. How many unique paths would there be? An obstacle and empty space is marked a
·
2015-11-11 17:46
LeetCode
【
LeetCode练习
题】Remove Duplicates from Sorted List II
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. For example, Given 1->2
·
2015-11-11 12:28
LeetCode
【
LeetCode练习
题】Recover Binary Search Tree
Recover Binary Search Tree Two elements of a binary search tree (BST) are swapped by mistake. Recover the tree without changing its structure. 互换二叉搜索树中两个位置错误的节点。 思路
·
2015-11-11 12:27
Binary search
【
LeetCode练习
题】Valid Palindrome
Valid Palindrome Given a string, determine if it is a palindrome, considering only alphanumeric characters and ignoring cases. For example,"A man, a plan, a canal: Panama" is
·
2015-11-11 12:23
LeetCode
191 Number of 1 Bits
最近想刷一下
LeetCode练习
一下数据结构算法之类的,先从水题开始吧 题目是这样的 Write a function that takes an unsigned integer and returns
·
2015-11-03 22:09
number
华为OJ平台:“编译错误”
一直在用
leetcode练习
,在华为OJ上提交题目时各种“编译错误”,十分郁闷。 这里记录一下我遇到的“编译错误”的原因。
yiting52
·
2015-09-16 16:00
数据结构与算法-
LeetCode练习
二分查找应用
LeetCode153.FindMinimuminRotatedSortedArray查找循环排序数组的最小元素(循环排序数组可以理解,一个环状数组(0,1,2,4,5,6,7),从其中一个元素断开后4,5,6,7,0,1,2)。查找一个数组的最小原始,我们知道最简单的方式就是循环遍历其中数字,时间复杂度O(n)肯定能找到这个元素。我们看循环排序数组的结构,我们发现我们的数组还不完全是一个乱序数组
Johnnyz1234
·
2015-08-30 13:00
LeetCode
数据结构
排序
二分查找
数组
华为OJ平台:“编译错误”
一直在用
leetcode练习
,在华为OJ上提交题目时各种“编译错误”,十分郁闷。 这里记录一下我遇到的“编译错误”的原因。
xiezhihua120
·
2014-07-03 17:00
编译错误
华为OJ平台
上一页
1
2
3
4
5
6
下一页
按字母分类:
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
其他