Description
You have just finished a compiler design homework question where you had to find the parse tree of an expression. Unfortunately you left your assignment in the library, but lucki...
分类:
其他好文 时间:
2014-07-18 22:19:15
阅读次数:
249
Given a binary tree, return thebottom-up level ordertraversal of its nodes' values. (ie, from left to right, level by level from leaf to root).For exa...
分类:
其他好文 时间:
2014-07-18 20:06:13
阅读次数:
255
CSS命名规则头:header 内容:content/containe 尾:footer 导航:nav 侧栏:sidebar 栏目:column 页面外围控制整体布局宽度:wrapper 左右中:left right center 登录条:loginbar 标志:lo...
分类:
Web程序 时间:
2014-07-17 22:16:09
阅读次数:
371
1.一个块级元素,设置了float left or right,如果又对它设置水平margin值,如margin-left margin-right,在IE6下间距会比设的这个值大。解决方案:该块级元素加hack: _display:inline;demo: ...
分类:
其他好文 时间:
2014-07-17 21:26:33
阅读次数:
215
??
Description
Petya has k matches, placed in n matchboxes lying in a line from left to right.
We know that k is divisible by n. Petya wants all boxes to have the same number of matches in...
分类:
其他好文 时间:
2014-07-17 20:35:53
阅读次数:
249
q次询问,每次询问可以对矩阵某一个值改变(0变1,1变0) 或者是查询子矩阵的最大面积,要求这个这个点在所求子矩阵的边界上,且子矩阵各店中全为1
用up[i][j]表示(i,j)这个点向上能走到的最长高度 若(i,j)为0 则up[i][j]值为0
同理,维护down,left, right数组
则每次查询时,从up[i][j]枚举至1作为子矩阵的高度,然后途中分别向左右扩展。若up[i]...
分类:
其他好文 时间:
2014-07-17 20:35:30
阅读次数:
320
在 CSS 中,类选择器以一个点号显示:
.center {text-align: center}
在上面的例子中,所有拥有 center 类的 HTML 元素均为居中。
在下面的 HTML 代码中,h1 和 p 元素都有 center 类。这意味着两者都将遵守 ".center" 选择器中的规则。
class="center">
This heading will be cent...
分类:
Web程序 时间:
2014-07-17 20:04:53
阅读次数:
246
sql表连接left join,right join,inner join区别left join(左联接) 返回包括左表中的所有记录和右表中联结字段相等的记录 (以左表数据为基准,不足补为NULL)right join(右联接) 返回包括右表中的所有记录和左表中联结字段相等的记录(以右表数据为基准,...
分类:
数据库 时间:
2014-07-17 13:34:45
阅读次数:
331
希望的效果如图:网上找了各纯css的做了下修改:代码如下:<!DOCTYPEhtmlPUBLIC"-//W3C//DTDXHTML1.0Strict//EN""http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<style>
.logo1{
width:150px;
height:60px;
float:left
}
a.alt{
position:relative;
backgr..
分类:
其他好文 时间:
2014-07-17 10:55:57
阅读次数:
231
A typical DFS usage, no big deal:class Solution {public: int dfs(TreeNode *p, int pval) { if( !p->left && !p->right ) { ...
分类:
其他好文 时间:
2014-07-17 09:55:25
阅读次数:
171