码迷,mamicode.com
首页 >  
搜索关键字:leedcode    ( 225个结果
[leedcode 229] Majority Element II
Given an integer array of sizen, find all elements that appear more than? n/3 ?times. The algorithm should run in linear time and in O(1) space.public...
分类:其他好文   时间:2015-08-08 16:23:35    阅读次数:106
[leedcode 228] Summary Ranges
Given a sorted integer array without duplicates, return the summary of its ranges.For example, given[0,1,2,4,5,7], return["0->2","4->5","7"].public cl...
分类:其他好文   时间:2015-08-08 16:14:37    阅读次数:94
[leedcode 227] Basic Calculator II
Implement a basic calculator to evaluate a simple expression string.The expression string contains onlynon-negativeintegers,+,-,*,/operators and empty...
分类:其他好文   时间:2015-08-08 16:13:23    阅读次数:89
[leedcode 225] Implement Stack using Queues
Implement the following operations of a stack using queues.push(x) -- Push element x onto stack.pop() -- Removes the element on top of the stack.top()...
分类:其他好文   时间:2015-08-08 14:54:53    阅读次数:98
[leedcode 224] Basic Calculator
Implement a basic calculator to evaluate a simple expression string.The expression string may contain open(and closing parentheses), the plus+or minus...
分类:其他好文   时间:2015-08-08 14:54:35    阅读次数:114
[leedcode 226] Invert Binary Tree
Invert a binary tree. 4 / \ 2 7 / \ / \1 3 6 9to 4 / \ 7 2 / \ / \9 6 3 1/** * Definition for a binary tree node...
分类:其他好文   时间:2015-08-08 14:51:13    阅读次数:111
[leedcode 222] Count Complete Tree Nodes
Given acompletebinary tree, count the number of nodes.Definition of a complete binary tree fromWikipedia:In a complete binary tree every level, except...
分类:其他好文   时间:2015-08-07 23:53:56    阅读次数:135
[leedcode 223] Rectangle Area
Find the total area covered by tworectilinearrectangles in a2Dplane.Each rectangle is defined by its bottom left corner and top right corner as shown ...
分类:其他好文   时间:2015-08-07 23:53:55    阅读次数:169
[leedcode 221] Maximal Square
Given a 2D binary matrix filled with 0's and 1's, find the largest square containing all 1's and return its area.For example, given the following matr...
分类:其他好文   时间:2015-08-07 21:54:10    阅读次数:116
[leedcode 217] Contains Duplicate
Given an array of integers, find if the array contains any duplicates. Your function should return true if any value appears at least twice in the arr...
分类:其他好文   时间:2015-08-07 00:09:44    阅读次数:174
225条   上一页 1 ... 4 5 6 7 8 ... 23 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!