这个小坑给了我两点思考: 1、有些花哨的用法如a.push.apply(a, b);还是用于面试题装逼就行,实战上还是多走老实路线免得遇到异常和性能的坑。 2、http://stackoverflow.com/questions/1374126 从stackoverflow找答案时不要仅盯着投票最多的,真理往往掌握在少数人手中,下图259票的回答是个坑,34票的才是最完美的分析。
1
2
3
a
= new Array();
b
= new Array(1256...
分类:
移动开发 时间:
2014-06-10 14:16:24
阅读次数:
300
如下图示,将net
GPR_0的鼠线隐藏。鼠标右键,选择网络----选择你要隐藏的网络------右键选择view nets----点击对话框右边View
List里你所选的网络-----在右下角traces plus the....和None两个打勾,点Apply,就ok了。
分类:
其他好文 时间:
2014-06-10 13:24:50
阅读次数:
585
An IO call issynchronousif, when you call it, it
does not return until the operation is completed, or until enough time has
passed that your network s...
分类:
编程语言 时间:
2014-06-10 10:07:56
阅读次数:
273
The oldest solution that people still use for
this problem is select(). The select() call takes three sets of fds (implemented
as bit arrays): one for...
分类:
编程语言 时间:
2014-06-10 08:26:42
阅读次数:
325
这一系列文章是写给刚开始使用Gradle,并且对Groovy语法不是特别了解的Java程序员看的。
本篇文章的目标是解释清楚下面这行Gradle脚本:
apply plugin: 'java'
行尾的分号是可选的
用过JavaScript语言的人对这个语法糖应该比较熟悉,下面是补上分号后的脚本:
apply plugin: 'java';
Map字面量(Literal)
Java语言...
分类:
其他好文 时间:
2014-06-10 06:57:10
阅读次数:
336
在了解回调函数之前,你应该先去了解函数指针!!!
先看一个回调函数的例子:
#include
#include
void Call(void (*fp)(int) ,int x) //Call为调用者,fp为指向回调函数的函数指针
{
fp(x);
}
void CallBackFun1(int x) //CallBackFun1为回调函数
{
printf("回调函数Ca...
分类:
其他好文 时间:
2014-06-10 06:48:19
阅读次数:
171
rite less, do
more.这句话想必是很多语言都提倡的。在此举三个jquery的应用体现一.绑定多个事件类型 $("div").bind("mouseover
mouseout", function () { $(this).toggleClass("over"); ...
分类:
Web程序 时间:
2014-06-09 20:47:18
阅读次数:
261
今天看博客时,看到了这样的一段js代码:var bind =
Function.prototype.call.bind(Function.prototype.bind);我想突然看到这样的一段代码,即使js能力再强的人,可能也需要花点时间去理解。像我这样的菜鸟就更不用说了。其实,原文已经对这端代码做...
分类:
移动开发 时间:
2014-06-08 22:10:19
阅读次数:
335
var add=function (a,b){ return(a+b);}var
sub=function (a,b,c){
return(a-b-c);}sub.call(add,1,2,3)//示例的意思时指用sub对象来替换add对象,并传入参数//使用call来实现继承function
.....
分类:
Web程序 时间:
2014-06-08 20:24:40
阅读次数:
290
sudo apt-get install mysql-server
装完后 是无法远程访问的.
要先修改
sudo vim /etc/mysql/my.cnf
找到 bind-address = 127.0.0.1
注释掉.就ok了
如果之前装乱了...
可以这样彻底删除
sudo apt-get remove --purge mysql-server
sudo a...
分类:
数据库 时间:
2014-06-08 03:56:15
阅读次数:
288