题目:Given a linked list, determine if it has a cycle in it.Follow up:Can you solve it without using extra space?题解:这道题连带着II是很经典的,在看CC150时候,纠结这个问题纠结了很久....
分类:
编程语言 时间:
2014-07-23 12:02:26
阅读次数:
311
1.在div元素中,包含了一个元素,通过has选择器获取元素中的元素的语法是?提示使用has $("div:has(span)")2.在三个元素中,分别添加多个元素,通过jQuery中的子元素选择器,将这三个元素中的第一个元素隐藏,代码是?提示使用first-child$("li:first-chi...
分类:
Web程序 时间:
2014-07-23 11:47:16
阅读次数:
230
最近安装了NDK
R8B,但是在cygwin下开始使用ndk-build时出现大量的如题所示的警告。于是,先GOOGLE一下,寻找模糊答案。又到NDK下载网站看
到,NDKR8B确实更新了C++编译器。而且,有网文介绍说,使用NDK
R8不会出现那样的警告。这个,我没有试验,估计OK(因为作者说他自己试验..
分类:
其他好文 时间:
2014-07-23 00:17:58
阅读次数:
178
说明:
最近两天在调研HBase的连接池,有了一些收获,特此记录下来。
本文先将官方文档(http://hbase.apache.org/book.html)9.3.1.1节翻译,方便大家阅读,然后查阅了关键类HConnectionManager的Developer API(http://hbase.apache.org/devapidocs/index.html) 做了一些总结。...
分类:
其他好文 时间:
2014-07-23 00:12:08
阅读次数:
466
- (void)connection:(NSURLConnection *)connection didFailWithError:(NSError *)error
NSURLConnection去加载一个URL请求时候有两种方式,一种是同步加载,一种是异步加载。
同步加载会阻塞当前的那个线程,如果将同步加载的代码放在主线程里去执行,那么就会阻塞主线程。
异步加载一种方式使用的是block,...
分类:
其他好文 时间:
2014-07-23 00:07:47
阅读次数:
368
Problem Description
DouBiXp has a girlfriend named DouBiNan.One day they felt very boring and decided to play some games. The rule of this game is as following. There are k balls on the desk. Every...
分类:
其他好文 时间:
2014-07-23 00:05:27
阅读次数:
344
Problem Description
Today the company has m tasks to complete. The ith task need xi minutes to complete. Meanwhile, this task has a difficulty level yi. The machine whose level below this task’s le...
分类:
其他好文 时间:
2014-07-22 23:57:27
阅读次数:
601
H. City HorizonTime Limit: 2000msMemory Limit: 65536KB64-bit integer IO format:%lld Java class name:MainFarmer John has taken his cows on a trip to th...
分类:
其他好文 时间:
2014-07-22 23:21:57
阅读次数:
263
我已经两次因为不恰当的省略go中的函数返回值,一次造成MySql的too many connection错误,一次造成严重的内存泄漏。所以在这里大家分享一下这个问题和解决办法,也提醒自己以后不要再犯类似的错了。 众所周知,g...
分类:
其他好文 时间:
2014-07-22 22:33:12
阅读次数:
227
Maven 2 repository Eclipse needs to know the path to the local maven repository. Therefore the classpath variable?M2_REPO?has to be set. Execute the following command: mvn?-Declipse.workspace=<...
分类:
系统相关 时间:
2014-07-22 22:32:54
阅读次数:
344