1 function createCORSRequest(method, url){ 2 var xhr = new XMLHttpRequest(); 3 4 if("withCredentials" in xhr){ 5 xhr.open(me...
分类:
其他好文 时间:
2014-06-27 22:02:10
阅读次数:
159
[ Talk is Cheap Show me the CODE ] : jQuery Mobile工具栏
Written In The Font
“ Wirte less Do more”
学习内容:
页眉工具栏和页眉按钮导航工具栏页脚工具栏定位工具栏
页眉工具栏和页眉按钮
页眉是网页身体的头不一样.下面我们演示下在页面工具栏中添加两个连接,中间...
分类:
Web程序 时间:
2014-06-25 20:07:02
阅读次数:
280
先上笑话,1.刚看到一个游泳的,想起公司组织去三亚旅游,老板跳海里,各种挣扎,捞上来老板第一句话:我记得我会游泳的啊。 2.媳妇说:老公对不起,我把你新买的自行车撞散架了! 老公:没事宝贝,你若安好,便是晴天! 媳妇说:老公你太有诗意了。 老公:滚犊子,安不好我整死你!数组的概念javascript...
分类:
编程语言 时间:
2014-06-25 11:39:25
阅读次数:
257
Well , you know. As a college student who want to find a good job after graduating like me , scores are not that important. I just want to have some low scores which can help me graduate successfully...
分类:
其他好文 时间:
2014-06-25 09:59:37
阅读次数:
202
欢迎关注我的新博客地址:http://cuipengfei.me/
Lower bound,不知道这个词的确切中文翻译是怎样的。我们直接看例子吧。
1
2
3
class Pair[T](val first: T, val second: T) {
def replaceFirst[R >: T](newFirst: R): Pair[R] ...
分类:
其他好文 时间:
2014-06-25 00:04:48
阅读次数:
381
dp[x]:能力为x的时候,逃出的期望。
则,可以根据x,来算出期望的公式。
#include
#include
#include
#include
using namespace std;
#define maxn 110000
#define eps 1e-6
#define zero(x) (fabs(x)<0?0:x)
double dp[maxn];
int c[maxn];
in...
分类:
其他好文 时间:
2014-06-24 23:43:09
阅读次数:
289
[ Talk is Cheap Show me the CODE ] : jQuery Mobile页面布局
当我们专注地研究人类生活的空虚,并考虑荣华富贵空幻无常时,也许我们正在阿谀逢迎自己懒惰的天性。
Written In The Font
为了app的手机端,我选择了 jQuery Mobile ,学习中出一系列的博客吧.我喜欢的一句话 “Talk is Chea...
分类:
Web程序 时间:
2014-06-24 23:34:39
阅读次数:
368
欢迎关注我的新博客地址:http://cuipengfei.me/
实在想不到什么动词可以当做脱衣服来讲了,所以从现在开始这系列博文就叫做Desugar Scala了。除非哪天才思泉涌,又想到了新词:)
开始正文。
名字叫做unapply和unapplySeq的方法在Scala里也是有特殊含义的。
我们前面说过case class在做pattern match时很...
分类:
移动开发 时间:
2014-06-24 19:42:48
阅读次数:
265
排序算法有不少,当然,一般的语言中都提供某个排序函数,比如Python中,对list进行排序,可以使用sorted(或者list.sort()),关于这方面的使用,在我的github代码库algorithm中有几个举例,有兴趣的看官可以去那里看看(顺便告知,我在Github中的账号是qiwsir,欢迎follow me)。但是,在某些情况下,语言中提供的排序方法或许不适合,必须选择某种排序算法。
...
分类:
其他好文 时间:
2014-06-24 18:33:33
阅读次数:
205
发送邮件是大家经常碰到的,接下来看一下使用pythonsmtplib模块发送邮件,好了废话不多说,直接上代码:importsmtplib,sys,os,timefromemail.mime.textimportMIMETextimportnewreportdefsend_mail(me,tomail,sub,content):#要发给谁,可以发送多个人mailto_list=[tomail+‘;‘]#..
分类:
编程语言 时间:
2014-06-24 17:02:29
阅读次数:
302