给定一个包含大写字母和小写字母的字符串,找到通过这些字母构造成的最长的回文串。 在构造过程中,请注意区分大小写。比如 "Aa" 不能当做一个回文字符串。 注意: 假设字符串的长度不会超过 1010。 示例 1: 输入: "abccccdd" 输出: 7 解释: 我们可以构造的最长的回文串是"dcca ...
分类:
其他好文 时间:
2018-08-28 01:00:27
阅读次数:
138
location[=|~|~|^~]/uri/{…}=开头表示精确匹配^~开头表示uri以某个常规字符串开头,理解为匹配url路径即可。nginx不对url做编码,因此请求为/static/20%/aa,可以被规则^~/static//aa匹配到(注意是空格)。~开头表示区分大小写的正则匹配~开头表示不区分大小写的正则匹配!~和!~*分别为区分大小写不匹配及不区分大小写不匹配的正则/通用匹配,任何
分类:
其他好文 时间:
2018-08-27 21:21:20
阅读次数:
193
练习题:26个字母大小写成对打印,例如:Aa,Bb....foriinrange(65,91):print(chr(i)+chr(i+32)+",",end="")2、一个list包含10个数字,然后生成新的list,要求,新的list里面的数都比之前的数多1list_1=list(range(10))result=[]fornuminlist_1:result.append(num+1)prin
分类:
编程语言 时间:
2018-08-27 14:19:52
阅读次数:
201
while循环 aa = 100 bb = 0 cc = 1 while cc >>")) print("你输入的数字是>>>",b) print("good bye!") while 循环使用else语句 count = 0 while count >>",wo) a = 100 while a ... ...
分类:
其他好文 时间:
2018-08-27 12:34:42
阅读次数:
133
变量声明const和let在ES6之前,我们都是用var关键字声明变量。无论声明在何处,都会被视为声明在函数的最顶部(不在函数内即在全局作用域的最顶部)。这就是函数变量提升例如: function aa() { if(bool) { var test = 'hello man' } else { c ...
分类:
其他好文 时间:
2018-08-26 20:47:10
阅读次数:
151
D. Concatenated Multiples You are given an array aa, consisting of nn positive integers. Let's call a concatenation of numbers xx and yy the number th ...
分类:
其他好文 时间:
2018-08-26 16:44:21
阅读次数:
187
[root@ckh ~] locale –a 列出系统所支持的所有字符集 aa_DJ aa_DJ.iso88591 aa_DJ.utf8 aa_ER aa_ER@saaho aa_ER.utf8 aa_ER.utf8@saaho ......... yum y groupinstall chines ...
分类:
其他好文 时间:
2018-08-25 21:17:22
阅读次数:
359
说明:我们知道Ajax是不能进行跨域请求的,我们是可以设置我们的项目让Ajax支持跨域访问。 跨域: aa.xxx.com 中用ajax请求 bb.ccc.com中的数据成为跨域。 找了一些文章看了的, 无非都是说 jsonp是get的解决办法,cross是post请求的解决办法。这边自己也测试了下 ...
分类:
Web程序 时间:
2018-08-25 11:46:29
阅读次数:
259
原文出处:numpy.where() 用法讲解 原创作者:massquantity numpy.where() 有两种用法: 1. np.where(condition, x, y) 满足条件(condition),输出x,不满足输出y 情景(一) >>> aa = np.arange(10) >> ...
分类:
其他好文 时间:
2018-08-24 11:40:42
阅读次数:
146
转自:https://blog.csdn.net/specter11235/article/details/71189486 一、笛卡尔积:itertools.product(*iterables[, repeat]) 直接对自身进行笛卡尔积: 输出结果: AA AB AC AD BA BB BC ...
分类:
编程语言 时间:
2018-08-23 15:47:45
阅读次数:
244