Given a stringSand a stringT, count the number
of distinct subsequences ofTinS.A subsequence of a string is a new string which
is formed from the orig...
分类:
其他好文 时间:
2014-05-10 19:10:58
阅读次数:
389
---恢复内容开始---MyEclipse启动tomcat出现Bad version number
in .class
file此错误时,可以用如下方法解决:找到MyEclipse的菜单,找到Window->Preferences,然后如下图操作,Add添加jdk安装的目录,并选择jre6为默认的环...
分类:
其他好文 时间:
2014-05-10 06:29:04
阅读次数:
311
最近拿到一个旧设备:BIG-IP LTM
6400,玩的人不在,文档又不足;只能自己玩了~SNAT模式下,走HTTP代理,往http
header中的x-forwarded-for加入源IP,以便让后端设备取得源IP万事不懂先问谷歌感谢以下:1、F5官方解答:可以通过两种方式,一是通过http
pr...
分类:
其他好文 时间:
2014-05-10 06:09:53
阅读次数:
1691
《一》数据类型(typeof)获取数据的类型;例如 var a=12;
alert(typeof a);弹出的 是 Number;1. 数值number 例如 var = 12,此时变量便是一个数值2. 字符串string 例如
var a = "abc";此时数据类型便是 字符串3 对象 obje...
分类:
其他好文 时间:
2014-05-10 06:05:09
阅读次数:
263
原题地址:http://www.cnblogs.com/x1957/p/3373994.html题意:Given
an array of integers, every element appearstwiceexcept for one. Find that single
one.要求:线性时间复...
分类:
编程语言 时间:
2014-05-10 05:22:27
阅读次数:
408
主程序代码 - 1 #include 2 #include 3 main() 4 { 5
long t1; 6 int i, n, t, t3; 7 char a[100]; 8 printf("please input a number
string:\n");...
分类:
其他好文 时间:
2014-05-10 03:10:56
阅读次数:
269
原题地址:http://oj.leetcode.com/problems/single-number-ii/题意:Given
an array of integers, every element appearsthreetimes except for one. Find that
single ...
分类:
编程语言 时间:
2014-05-10 03:01:41
阅读次数:
413
我的那个暴力求解,太耗时间了。用了网上产的什么因式分解,质因数之类的。确实快!还是数学基础不行,只能知道大约。The
sequence of triangle numbers is generated by adding the natural numbers. So the
7th triangl...
分类:
其他好文 时间:
2014-05-09 23:43:16
阅读次数:
342
题意:
定义函数F(x) :
区间[1,x]上的y是满足:GCD(x,y)>1 && x%y>0的 y的个数。
问:对于任意区间[l,r] 上的F(l···r) 有几个函数值是奇数的。
打表找规律。
打的是[1,x]区间的结果
把所有结果不相同的值打出来(因为结果是递增的,所以只观察不相同的结果)
发现:ans = x/2-2 || x/2-1
再把所有结果不同 &...
分类:
其他好文 时间:
2014-05-09 22:26:35
阅读次数:
424
关键字Rabin karp 算法,C++,ubuntu 14.04, linux, big
integer, gmp为了计算冗余度, 我写出了如下算法void HandleAMission(const char *srcFileName, FILE
*output, int blockSize, i...
分类:
其他好文 时间:
2014-05-09 20:12:25
阅读次数:
270