??
Eclipse有时候不能生成R.java文件,非常烦人。这时候,我们可以手工生成它。
命令为:
aapt package --non-constant-id -f -m -M
-S -I
-J<abs_path_to_dir_that_should_contain_gen_R_java)
--generate-depe...
分类:
移动开发 时间:
2015-06-23 18:09:16
阅读次数:
147
#14 Longest Common Prefix
Write a function to find the longest common prefix string amongst an array of strings.
这个题求多个字符串的公共前缀,除了要考虑串空外,如果存在公共前缀,那么必定也是第一个串的前缀。
所以可以以第一个串为基准,比较其他串的前缀是否与第一个串相同。
c...
分类:
其他好文 时间:
2015-06-23 11:55:01
阅读次数:
129
maven作为一个高度自动化构建工具,本身提供了构建项目的功能,下面就来体验一下使用maven构建项目的过程。一、构建Jave项目1.1、创建Jave Project 1、使用mvn archetype:generate命令,如下所示:mvn archetype:generate -DgroupI....
分类:
其他好文 时间:
2015-06-23 11:23:06
阅读次数:
112
This problem can be solved elegantly using dynamic programming.We maintain two arrays:cnt[i][j] --- number of parentheses needed to add within s[i..j]...
分类:
其他好文 时间:
2015-06-22 19:12:15
阅读次数:
202
Given two integers representing the numerator and denominator of a fraction, return the fraction in string format.
If the fractional part is repeating, enclose the repeating part in parentheses.
...
分类:
其他好文 时间:
2015-06-22 15:03:43
阅读次数:
181
在maven里使用mvn archetype:generate来创建项目是十分方便的,但有时也不尽然。在网络不好时,从网络上加载 archetype-catalog.xml文件(http://repo1.maven.org/maven2/archetype-catalog.xml)时需要很长时间,同...
分类:
其他好文 时间:
2015-06-21 13:09:25
阅读次数:
105
GivennumRows, generate the firstnumRowsof Pascal's triangle.For example, givennumRows= 5,Return[ [1], [1,1], [1,2,1], [1,3,3,1], [1,4,6,4,1]...
分类:
其他好文 时间:
2015-06-21 10:36:06
阅读次数:
121
最近参考了园友的自动生成目录的方法,我增加了能够自动生成三级目录的JS代码。把上述JS代码复制到“页脚Html代码”里。在写博客的时候,给每个章节的标题设置“标题1”或“标题2”或“标题3”格式。然后一切就绪,欣赏效果吧。这里有个例子(http://www.cnblogs.com/bitzhuwei...
分类:
Web程序 时间:
2015-06-21 01:55:30
阅读次数:
228
Classes in JSBindingSettings.classes array will be exported to JavaScript.There are already many classes (most of them are from UnityEngine.dll) in th...
分类:
Web程序 时间:
2015-06-20 20:53:23
阅读次数:
133
Description:GivennumRows, generate the firstnumRowsof Pascal's triangle.For example, givennumRows= 5,Return[ [1], [1,1], [1,2,1], [1,3,3,1],...
分类:
其他好文 时间:
2015-06-20 17:01:48
阅读次数:
99