使用Eclipse可以方便的统计工程或文件的代码行数,方法如下:? 1.点击要统计的项目或许文件夹,在菜单栏点击Search,然后点击File...? 2.选中正则表达式(Regular expression),并在搜索文本框输入\n? 3.在文件...
分类:
系统相关 时间:
2014-09-19 15:48:55
阅读次数:
334
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 n...
分类:
其他好文 时间:
2014-09-19 04:28:05
阅读次数:
247
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 ...
分类:
其他好文 时间:
2014-09-19 01:06:54
阅读次数:
301
Abinarysearchtreeis provided for efficiently organizing values for a set of items, even when values are duplicated. In generating thebinarysearchtree,...
分类:
其他好文 时间:
2014-09-18 23:36:54
阅读次数:
201
根据EditText搜索框ListView动态显示数据是根据需求来的,觉得这之中涉及的东西可能比较的有意思,所以动手来写一写,希望对大家有点帮助。
首先,我们来分析下整个过程:
1、建立一个layout,包含一个EditText搜索框和一个ListView
2、创建一个数据集mData,用于ListView的Adapter的创建
3、添加EditText的文本改变的监听器
4、利...
分类:
移动开发 时间:
2014-09-18 20:44:24
阅读次数:
267
由于公司需要,小菜最近在搞app web开发,目前只有ios和android版本,虽然仅此两个版本,但是依然要考虑浏览器兼容性问题,因为android和ios默认浏览器内核是不一样的。 先说说兼容性问题是什么。假如有这样一个URL:http://www.kpdown.com/search?na...
分类:
Web程序 时间:
2014-09-18 20:28:14
阅读次数:
336
git remotegit remote基本使用基本使用git是一个分布式代码管理工具,所以可以支持多个仓库,在git里,服务器上的仓库在本地称之为remote。直接clone一个仓库:$: git clone git@search.ued.taobao.net:projects/search.gi...
分类:
其他好文 时间:
2014-09-18 20:23:54
阅读次数:
299
<scripttype="text/javascript">varurl=window.location.search;//定义变量window.location.hreffunctionparse_url(_url){//定义函数varpattern=/(\w+)=(\w+)/ig;//定义正则表达式varparames={};//定义数组url.replace(pattern,function(a,b,c){parames[b]=c;});/*这是最..
分类:
Web程序 时间:
2014-09-18 19:09:25
阅读次数:
212
tar式安装 -x,从归档中解出文件 -f,使用归档文件或 ARCHIVE 设备 -z,通过 gzip 过滤归档 -v,详细地列出处理的文件gcc用yum search gcc搜索,yum install gcc安装需安装pecl步骤configure --prefix=/dta make make...
分类:
其他好文 时间:
2014-09-18 18:18:14
阅读次数:
196
Follow up for "Search in Rotated Sorted Array":What if duplicates are allowed?Would this affect the run-time complexity? How and why?Write a function ...
分类:
其他好文 时间:
2014-09-18 13:11:03
阅读次数:
135