Given an array S of n integers, are there
elements a, b, c in S such that a + b + c = 0? Find all unique triplets in the
array which gives the sum of ...
分类:
其他好文 时间:
2014-05-09 10:27:29
阅读次数:
449
之前在ubuntu上安装pandas,用的easy_install。这次在window上同样方法装遇到"unable
to find
vcvarsall.bat",看一些网上帖子好像说这个要装minGW解决,不喜欢装那么东西。就直接下exe装pandas,但也遇到问题,在注册表里找不到python2...
戳我去解题Given amxnmatrix, if an element is 0, set its
entire row and column to 0. Do it in
place.这题还是很简单的,就是有点坑,遍历矩阵的时候,每遇到0的时候,我们不能立即将所在行和列置0,否则,到最后矩阵所有...
分类:
其他好文 时间:
2014-05-09 08:51:57
阅读次数:
253
完成了一个脚本,find.sh如果希望可以再linux系统中任何位置都可以执行该脚本,可以执行下面操作1. chmod 775 find.sh
给该脚本增加可执行权限2. export PATH=$PATH:存放该脚本的路径
分类:
系统相关 时间:
2014-05-09 08:16:43
阅读次数:
498
<p><%=course=Course.find_by_id(params[:id])%></p>
分类:
数据库 时间:
2014-05-09 06:43:34
阅读次数:
320
1) 错误:The prefix "context" for element "context:property-placeholder" is not bound.
解决:在文件头中引入:xmlns:context="http://www.springframework.org/schema/context" 即可。
正解例子:
xmlns:xsi="http://www...
分类:
其他好文 时间:
2014-05-09 02:16:02
阅读次数:
406
这道题是为数不多的感觉在读本科的时候见过的问题。人工构造的过程是怎样呢,后续遍历最后一个节点一定是整棵树的根节点,从中序遍历中查找到这个元素,就可以把树分为两颗子树,这个元素左侧的递归构造左子树,右侧的递归构造右子树,元素本身分配空间,作为根节点。
于set和map容器不同的是,vector容器不含find的成员函数,应该用stl的库函数,好在返回的也是迭代器,而vector的迭代器之间是可以做...
分类:
其他好文 时间:
2014-05-09 01:23:38
阅读次数:
275
这几个月正式开始运用ExtJS开发项目,接下来会将这几个月的一些经验整理成一个系列博客。今天要讲的是ExtJS中的基础,如何获取component和Dom.element。一、query查询以下的path为查询条件,查询方式类似于JQuery*ComponentQuery返回componentExt.ComponentQuery.query(path)全..
分类:
Web程序 时间:
2014-05-09 00:44:37
阅读次数:
413
Sizzle( selector, context, results, seed )的关键步骤
1,传入的context对应的context和当前document是否一致,不一致调用setDocument()重新设置document,用于frame的情况.
2,如果context为空修正context为document
3,selector如果不是字符串或者context不是Element或...
分类:
Web程序 时间:
2014-05-09 00:32:34
阅读次数:
400
Many people who transition from 35mm film to a
smaller digital camera are surprised to find that many of their digital images
are blurry. The underlyi...
分类:
其他好文 时间:
2014-05-08 23:51:44
阅读次数:
389