(1)冒泡型事件:事件按照从最特定的事件目标到最不特定的事件目标(document对象)的顺序触发。 IE 5.5: div -> body -> document IE 6.0: div -> body -> html -> document Mozilla 1.0: div -> body ->...
分类:
其他好文 时间:
2015-08-02 16:30:31
阅读次数:
132
You have two friends. You want to present each of them several positive integers. You want to presentcnt1numbers to the first friend andcnt2numbers to...
分类:
其他好文 时间:
2015-08-02 16:31:21
阅读次数:
124
Sublime Text 3与Sublime Text 2的不同其实有不少人写过如何让Sublime Text 2支持GB2312和GBK编码,例如这篇。基本原理就是先装好Package Control,然后再通过这个安装ConvertToUTF8的Package。但是文中的方法在Sublime T...
分类:
其他好文 时间:
2015-08-02 16:30:21
阅读次数:
126
例子1:class A { val x1: String = "hello" val x2: String = "mom" println("A: x1=" + x1 + ",x2=" + x2)}class B extends A { override val x2: String = "...
分类:
其他好文 时间:
2015-08-02 16:28:59
阅读次数:
112
Description:Write a program that finds and displays all pairs of 5-digit numbers that between them use the digits0through9once each, such that the fir...
分类:
其他好文 时间:
2015-08-02 16:27:59
阅读次数:
160
Outputting Strings in the Console #include class Console {public: enum fore_color { f_black = 0 , f_white = FOREGROUND_INTENSITY | FOREGROUND_RED | .....
分类:
其他好文 时间:
2015-08-02 16:30:17
阅读次数:
117
File.Create(@"C:\Users\shuai\Desktop\new.txt"); Console.WriteLine("创建成功"); Console.ReadKey(); File.Delete...
分类:
其他好文 时间:
2015-08-02 16:28:38
阅读次数:
98
转自:http://www.open-open.com/lib/view/open1385685943484.htmlmapreduce是一种模式,一种什么模式呢?一种云计算的核心计算模式,一种分布式运算技术,也是简化的分布式编程模式,它主要用于解决问题的程序开发模型,也是开发人员拆解问题的方法。如...
分类:
其他好文 时间:
2015-08-02 16:27:45
阅读次数:
110
Using RUNDLL32.exe to call a function within a dll Rundll32 is a utility included with Windows that allows you to execute an exported DLL-function fr....
分类:
其他好文 时间:
2015-08-02 16:29:56
阅读次数:
111
Write a function to delete a node (except the tail) in a singly linked list, given only access to that node.Supposed the linked list is1 -> 2 -> 3 -> ...
分类:
其他好文 时间:
2015-08-02 16:27:59
阅读次数:
112
Collection接口 Collection是最基本的集合接口,一个Collection代表一组Object,即Collection的元素(Elements)。一些Collection允许相同的元素而另一些不行。一些能排序而另一些不行。JavaSDK不提供直接继承自Collection的类,Ja....
分类:
其他好文 时间:
2015-08-02 16:28:10
阅读次数:
97
通道题意:二维坐标上的点,建一个长度和最小的树包含全部点思路:定义状态 dp[i,j]表示点i到点j合并在一起的最小花费(树枝的长度),状态转移方程:dp[i,j]= min(dp[i,k]+dp[k+1,j]+cost(i,j) ) i #include #include #include...
分类:
其他好文 时间:
2015-08-02 16:28:16
阅读次数:
118
求一个括号的最大匹配数,这个题可以和UVa 1626比较着看。注意题目背景一样,但是所求不一样。回到这道题上来,设d(i, j)表示子序列Si ~ Sj的字符串中最大匹配数,如果Si 与 Sj能配对,d(i, j) = d(i+1, j-1)然后要枚举中间点k,d(i, j) = max{ d(i,...
分类:
其他好文 时间:
2015-08-02 16:27:16
阅读次数:
101
前端大牛:冯鲁哲 1033850519 承接各种web开发业务 欢迎洽谈-------鲁大师Bootstrap 附加导航(Affix)插件 Bootstrap Affix 第一部分 ...
分类:
其他好文 时间:
2015-08-02 16:27:27
阅读次数:
115
思路:首先把所有点按照坐标排序,然后以每一个点为基准点,计算其他点与这个点连线的斜率,将所有斜率排序后求最多的相同的斜率数即可。 1 #include 2 #include 3 #include 4 #include 5 #include 6 #include 7 #include 8...
分类:
其他好文 时间:
2015-08-02 16:27:27
阅读次数:
101
You are climbing a stair case. It takes n steps to reach to the top.Each time you can either climb 1 or 2 steps. In how many distinct ways can you cli...
分类:
其他好文 时间:
2015-08-02 16:25:34
阅读次数:
125
很多Sublime新人都遇到了这个问题,到网上搜,信息很片面,而且不少都是旧版本的。于是有了这篇文章。 默认Sublime使用Ctrl+`作为快捷键弹出Console,但不同的系统抑或安装过不同的软件后,会引起热键冲突。此时如果你不知道究竟那个程序占用了Ctrl+`,只要修改Sublime配置就可以...
分类:
其他好文 时间:
2015-08-02 16:25:12
阅读次数:
200