题目:http://www.lydsy.com/JudgeOnline/problem.php?id=3916复习一下hash(然后被傻叉错误卡了半天TAT。。。取出一个字串:h[r]-h[l-1]*power[r-l+1] 然后匹配。。。注意一下当前需要的是s[i]还是s[i-1],做hash数组...
分类:
其他好文 时间:
2015-11-26 22:53:42
阅读次数:
199
字符串哈希..然后枚举每一位+各种判断就行了--------------------------------------------------------------------------------#include#include#includeusing namespace std;type...
分类:
其他好文 时间:
2015-11-25 23:19:16
阅读次数:
223
11722 - Joining with FriendYou are going from Dhaka to Chittagong by train and you came to know one of your old friends is goingfrom city Chittagong t...
分类:
其他好文 时间:
2015-11-24 20:28:16
阅读次数:
147
题目概述: One day Squidward, Spongebob and Patrick decided to go to the beach. Unfortunately, the weather was bad, so the friends were unable to ride wav....
分类:
其他好文 时间:
2015-11-24 12:34:43
阅读次数:
150
B. Kefa and CompanyKefa wants to celebrate his first big salary by going to restaurant. However, he needs company.Kefa has n friends, each friend will...
分类:
其他好文 时间:
2015-11-23 13:07:47
阅读次数:
155
在python中,模拟http客户端发送get和post请求,主要用httplib模块的功能。1、python发送GET请求我在本地建立一个测试环境,test.php的内容就是输出一句话:1echo 'Old friends and old wines are best.';python发送get请...
分类:
编程语言 时间:
2015-11-23 11:22:59
阅读次数:
187
// 借用构造函数// 其基本思路是在子类型构造函数的内部调用父类型的构造函数function Person(name){ this.name = name; this.friends = ["Jack","John","Kim"];}function SuperPerson(name,sex).....
分类:
Web程序 时间:
2015-11-10 19:08:20
阅读次数:
161
// 原型式继承// 其基本思路是借助原型可以基于已有的对象创建新的对象function object(o){ function F(){} F.prototype = o; return new F();}var person = { name: "Tom", friends: ["Jack...
分类:
Web程序 时间:
2015-11-10 19:06:56
阅读次数:
164
// 组合继承// 其基本思路是使用原型链实现对原型属性和方法的继承,而通过借用构造函数来实现对实例属性的继承function Person(name){ this.name = name; this.friends = ["Jack","John","Kim"];}Person.prototy.....
分类:
Web程序 时间:
2015-11-10 19:03:53
阅读次数:
132
程序员中有一类叫做程序媛,她们和所有的程序员一样,愁嫁 @蓝翔妓工:女程序员是这么征婚的: SELECT * FROM 男人们WHERE 未婚=true and Gay=false and 有房=true and 有车=true and 条件in (帅气,绅士,大度,气质...
分类:
其他好文 时间:
2015-11-06 08:30:59
阅读次数:
239