原题:DescriptionLetxandybe two strings over some finite alphabetA. We would like to transformxintoyallowing only operations given below:Deletion:a lette...
分类:
其他好文 时间:
2015-08-15 18:12:01
阅读次数:
93
DescriptionLetxandybe two strings over some finite alphabetA. We would like to transformxintoyallowing only operations given below:Deletion:a letter i...
分类:
其他好文 时间:
2015-08-15 16:13:32
阅读次数:
119
Power Strings
Time Limit: 3000MS
Memory Limit: 65536K
Total Submissions: 37817
Accepted: 15653
Description
Given two strings a and b we define a*b to be their concate...
分类:
其他好文 时间:
2015-08-15 11:58:34
阅读次数:
111
problem:Given two string, write a method to decide if one is a permutation of the otherSolution:1. sort two strings and return weather str1 equal to s...
分类:
其他好文 时间:
2015-08-15 06:45:36
阅读次数:
139
题目大意:叙述的比较高大上,其实就是一个字符串B = AAAAAAA,求出来这个A最短有多长分析:注意如果这个串不是完全循环的,那么循环节就是就是它本身。代码如下:#include#includeconst int MAXN = 1e6+7;const int oo = 1e9+7;char s[M...
分类:
其他好文 时间:
2015-08-14 21:17:40
阅读次数:
200
网上有很多关于二维码扫码和二维码生成的Demo,你可能不想透彻的了解它是如何实现的,但是你必须要知道如何引入到你的项目之中,我们研究一下如何将这些Demo引入到自己的项目之中。
我也写了一个Demo,看一下它的目录结构。
这些打红色箭头的部分都是必须要复制到你的项目之中的。引入到你的项目之后会有一些报错,你可以根据错误提示进行修改。
strings里面有一个字段要加入到你的项目之中...
分类:
移动开发 时间:
2015-08-14 19:12:49
阅读次数:
208
http://www.tsinsen.com/A1484 在线插入并不好做,我们将所有操作离线,变为删除操作。 每次询问的时候对于当前B串所在起始位置及其长度向上向下二分,然后查询区间内合法的当前A串内的匹配点即可。用树状数组维护。#includeusing namespace std;cons.....
分类:
其他好文 时间:
2015-08-14 18:49:29
阅读次数:
100
今天在自己实现strlen函数的时候碰到碰到了一个很有意思的warning:warning: deprecated conversion from string constant to 'char*' [-Wwrite-strings] 1 #include 2 3 int strlen(cha.....
分类:
其他好文 时间:
2015-08-14 00:53:52
阅读次数:
237
importreadline
importqrcode
fromPILimportImage
importos
defCreate_Qrcode(strings,path,logo=""):
qr=qrcode.QRCode(
version=2,
error_correction=qrcode.constants.ERROR_CORRECT_L,
box_size=6,
border=1,
)
withopen(‘test.txt‘,‘r‘)asfr:
forlinesinfr.readlines():..
分类:
编程语言 时间:
2015-08-13 20:23:56
阅读次数:
285
Redis的数据类型(1)Strings类型及操作String是最简单的类型,一个Key对应一个Value,string类型是二进制安全的,Redis的string可以包含任何数据,比如jpg图片或者序列化的对象1.Set 设置key对应的值为string类型的value 例如:我们添加一个na.....
分类:
其他好文 时间:
2015-08-13 20:07:34
阅读次数:
257