SQL语句如下:SELECT * FROM 表1 LEFT JOIN 表2 ON 表1.id = 表2.id AND 表2.Name != 'ff'WHERE 表1.NAME != 'aa' 步骤1:返回笛卡尔积(SELECT * FROM表1 CROSS JOIN表2) 步骤2:应用ON筛...
分类:
数据库 时间:
2014-07-10 00:04:24
阅读次数:
266
一.HTML 商品1 @RenderBody() 二.CSS/*瀑布流浏览方式*/.main{ width: 720px; height:auto; border: 1px solid #cccccc; margin-left: 12px;...
分类:
其他好文 时间:
2014-07-08 00:09:24
阅读次数:
319
Given an array of words and a length L, format the text such that each line has exactly L characters and is fully (left and right) justified.
分类:
其他好文 时间:
2014-07-07 23:16:20
阅读次数:
274
Given a binary tree struct TreeLinkNode { TreeLinkNode *left; TreeLinkNode *right; TreeLinkNode *next; }Populate each next pointe...
分类:
其他好文 时间:
2014-07-07 23:09:49
阅读次数:
298
After a perfect inning from Farnsworth in the eighth, the Yankees would have Alex Rodriguez coming to the plate to lead off the inning. Guillen left C...
分类:
其他好文 时间:
2014-07-07 20:49:01
阅读次数:
260
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 path.
分类:
其他好文 时间:
2014-06-27 23:02:33
阅读次数:
258
题目链接:http://acdream.info/problem?pid=1108
题意:n个数的数列,m次查询某个区间出现次数第k多的数出现的次数。n,m
解法:这个因为是离线的所以可以先统一处理,然后再输出。可以维护一个left和right指针,pre,pre[i]表示此时区间内出现次数大于等于i的数的种类。为了减少复杂度,关键是left和right的移动方式,即查询区间如何排...
分类:
其他好文 时间:
2014-06-27 09:38:07
阅读次数:
255
1.基本的,eclipse的特色CTRL + D 删除当前行ALT + Up/Down 上移 下移当前行CTRL+ALT+UP/DOWN 复制当前行,并粘贴到下一行。如果选中了多行(可按下shift+up/down选中多行),一次复制粘贴多行。eclipse经典快捷键,一定要学会!ALT + Left/Right eclipse记住了你编辑的地方,按下这两个键可以在历史编辑处来回跳转。同时编辑多个...
分类:
系统相关 时间:
2014-06-27 09:24:51
阅读次数:
286
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 with keys less than the node's key....
分类:
其他好文 时间:
2014-06-27 09:15:12
阅读次数:
196
分析:
还是二叉树遍历模板的改造问题,对于二叉搜索树,中序遍历的结果是有顺序的。题目的要求无非是将中序遍历的结点访问结果链接起来,至于双向链表,通过复用树结点的left 和 right 指针就可以完成。最直接的就是我们可以把中序遍历中访问到的每个结点都放入到个队列里,然后将队列的元素链接起来,但是题目不允许用额外的空间。
想想中心遍历,遍历顺序是 左 --根---右,那么中序遍历的第一个访问结...
分类:
其他好文 时间:
2014-06-27 07:56:13
阅读次数:
341