检查回文字符串 如果给定的字符串是回文,返回true,反之,返回false。 如果一个字符串忽略标点符号、大小写和空格,正着读和反着读一模一样,那么这个字符串就是palindrome(回文)。 注意你需要去掉字符串多余的标点符号和空格,然后把字符串转化成小写来验证此字符串是否为回文。 函数参数的值可 ...
分类:
其他好文 时间:
2017-09-03 01:12:57
阅读次数:
245
LeetCode真是个好东西,本来闲了一下午不想看书,感觉太荒废时间了就来刷一道题。能力有限,先把easy的题目给刷完。 Determine whether an integer is a palindrome. Do this without extra space. 确定一个整数是否是回文。 做 ...
分类:
其他好文 时间:
2017-09-02 23:23:32
阅读次数:
218
整数 浮点数 字符串 对象 创建列表 方式一:创建一个普通列表 >>>member = ['jhon', 'dog', 'pig' ] >>>member ['jhon', 'dog', 'pig' ] 方式二: 创建一个混合列表 >>>mix = [1, 'fish', 3.14, [1, 2, ...
分类:
编程语言 时间:
2017-08-31 23:08:54
阅读次数:
193
Keeping track of all the cows can be a tricky task so Farmer John has installed a system to automate it. He has installed on each cow an electronic ID ...
分类:
其他好文 时间:
2017-08-27 00:15:35
阅读次数:
271
旋转链表函数 public ListNode reverse(ListNode head) { ListNode prev = null; while (head != null) { ListNode next = head.next; head.next = prev; prev = head; ...
分类:
其他好文 时间:
2017-08-26 21:23:39
阅读次数:
158
Given a string s, cut s into some substrings such that every substring is a palindrome. Return the minimum cuts needed for a palindrome partitioning o ...
分类:
其他好文 时间:
2017-08-26 12:46:40
阅读次数:
226
Splits the string 时间限制:1000 ms | 内存限制:65535 KB 难度:3 Hrdv is interested in a string,especially the palindrome string.So he wants some palindrome string ...
分类:
编程语言 时间:
2017-08-25 21:44:14
阅读次数:
420
原文出自 http://blog.fens.me/Hadoop-family-roadmap/ Hadoop家族学习路线图 Hadoop家族系列文章,主要介绍hadoop家族产品,常用的项目包括Hadoop, Hive, Pig, Hbase, Sqoop, Mahout, Zookeeper, A ...
分类:
其他好文 时间:
2017-08-25 15:04:37
阅读次数:
143
As we all know,a palindrome number is the number which reads the same backward as forward,such as 666 or 747.Some numbers are not the palindrome numbe ...
分类:
其他好文 时间:
2017-08-25 15:03:03
阅读次数:
147