You are given annxn2D matrix representing an
image.Rotate the image by 90 degrees (clockwise).Follow up:Could you do this
in-place?思路:先将矩阵转置,然后将第一列与最后...
分类:
其他好文 时间:
2014-05-14 03:09:35
阅读次数:
225
You are given a string, S, and a list of words,
L, that are all of the same length. Find all starting indices of substring(s) in
S that is a concatena...
分类:
其他好文 时间:
2014-05-12 22:27:04
阅读次数:
265
原题地址:http://oj.leetcode.com/problems/binary-tree-level-order-traversal-ii/题意:Given
a binary tree, return thebottom-up level ordertraversal of its node...
分类:
编程语言 时间:
2014-05-12 22:03:27
阅读次数:
581
Best Time to Buy and Sell StockSay you have an
array for which theithelement is the price of a given stock on dayi.If you were
only permitted to compl...
分类:
其他好文 时间:
2014-05-12 05:56:14
阅读次数:
315
原题地址:http://oj.leetcode.com/problems/flatten-binary-tree-to-linked-list/题意:Given
a binary tree, flatten it to a linked list in-place.For example,Given...
分类:
编程语言 时间:
2014-05-12 05:30:32
阅读次数:
367
原题地址:http://oj.leetcode.com/problems/sum-root-to-leaf-numbers/题意:Given
a binary tree containing digits from0-9only, each root-to-leaf path could
repre...
分类:
编程语言 时间:
2014-05-12 01:28:30
阅读次数:
440
1、
??
Surrounded Regions
Given a 2D board containing 'X' and 'O',
capture all regions surrounded by 'X'.
A region is captured by flipping all 'O's into 'X's
in that surrounded region.
For e...
分类:
其他好文 时间:
2014-05-11 18:52:32
阅读次数:
293
题目链接:http://poj.org/problem?id=3468
A Simple Problem with Integers
Time Limit: 5000MS
Memory Limit: 131072K
Total Submissions: 56005
Accepted: 16903
Case Time Limit...
分类:
其他好文 时间:
2014-05-11 18:40:16
阅读次数:
301
本文为senlie原创,转载请保留此地址:http://blog.csdn.net/zhengsenlie
Single Number II
Total Accepted: 14224 Total
Submissions: 43648
Given an array of integers, every element appears three ti...
分类:
其他好文 时间:
2014-05-11 03:54:46
阅读次数:
317
题目
Given a binary tree, find the maximum path sum.
The path may start and end at any node in the tree.
For example:
Given the below binary tree,...
分类:
其他好文 时间:
2014-05-11 03:25:24
阅读次数:
298