原题地址:https://oj.leetcode.com/problems/anagrams/题意:Given
an array of strings, return all groups of strings that are anagrams.Note: All
inputs will be i...
分类:
编程语言 时间:
2014-06-29 13:25:28
阅读次数:
355
题目
Given preorder and inorder traversal of a tree, construct the binary tree.
Note:
You may assume that duplicates do not exist in the tree.
方法
根据树的中序遍历和前序遍历,来构造树,使用递归的思想。
Tre...
分类:
其他好文 时间:
2014-06-20 12:14:49
阅读次数:
262
题目
Given a binary tree, return the inorder traversal of its nodes' values.
For example:
Given binary tree {1,#,2,3},
1
2
/
3
return [1,3,2].
Note: Recur...
分类:
其他好文 时间:
2014-06-20 10:22:00
阅读次数:
221
题目
Given inorder and postorder traversal of a tree, construct the binary tree.
Note:
You may assume that duplicates do not exist in the tree.
方法
根据树的中序遍历和后序遍历,来恢复树,使用递归的思想。
Tr...
分类:
其他好文 时间:
2014-06-07 14:50:37
阅读次数:
231
This is the beginning of my plan. Or this is a
manifesto, a motivation for me. Note what I read, good or bad, old or new, Tao
or method. Maybe sometim...
分类:
其他好文 时间:
2014-06-05 15:57:51
阅读次数:
373
1、Android设备屏幕尺寸分布
首先看一下各种屏幕的尺寸和屏幕密度划分,下图是各种屏幕尺寸对应的范围:
从上图可以看出,对应normal尺寸的屏幕范围集中在常见的3到5寸屏之间,large尺寸对应的就主要是5到7寸的nottpad之类的设备,例如三星的Note和Nexus7平板等,再网上走就是平板电脑了。接下来是屏幕密度(dpi),需要说明的时,平时所说的屏幕分辨率其实不能...
分类:
移动开发 时间:
2014-06-04 13:43:01
阅读次数:
459
Te Regular Expression literal also creates new
objects in ECMA Script 5. And one last note that calling RegExp() without new(as
a function, not as a c...
分类:
编程语言 时间:
2014-06-02 15:50:52
阅读次数:
280
【题目】
Two elements of a binary search tree (BST) are swapped by mistake.
Recover the tree without changing its structure.
Note:
A solution using O(n) space is pretty straight forward. Could you devise a constant space solution?
confused what "{1,#,2,3}" ...
分类:
其他好文 时间:
2014-06-02 10:38:17
阅读次数:
246
Subsets
Total Accepted: 13267 Total
Submissions: 48509My Submissions
Given a set of distinct integers, S, return all possible subsets.
Note:
Elements in a subset must be in non-desc...
分类:
其他好文 时间:
2014-06-02 10:28:35
阅读次数:
186
可视化语法 Visual Format SyntaxThe following are
examples of constraints you can specify using the visual format. Note how the
text visually matches the im...
分类:
移动开发 时间:
2014-06-02 05:37:46
阅读次数:
351