题目链接:https://vjudge.net/problem/UVA-11475 题意: 给你一个串S 你可以在结尾补充任意数量字母,问最少数量使得新串是回文串 题解: KMP 将S串倒置跑KMP ...
分类:
其他好文 时间:
2017-07-24 00:02:04
阅读次数:
170
Given a string, determine if it is a palindrome, considering only alphanumeric characters and ignoring cases. For example,"A man, a plan, a canal: Pan ...
分类:
其他好文 时间:
2017-07-22 15:32:52
阅读次数:
142
Given a singly linked list, determine if it is a palindrome. Follow up:Could you do it in O(n) time and O(1) space? Similar Questions Palindrome Numbe ...
分类:
其他好文 时间:
2017-07-21 21:58:24
阅读次数:
155
Palindrome Names Kattis - names Anna and Bob are having a baby. They both enjoy the advantage of having palindrome names, meaning that their names are ...
分类:
其他好文 时间:
2017-07-18 23:14:56
阅读次数:
266
C. Palindrome Again !! Given string with N characters, your task is to transform it to a palindrome string. It's not as easy as you may think because ...
分类:
其他好文 时间:
2017-07-17 22:07:52
阅读次数:
257
H. Special Palindrome A sequence of positive and non-zero integers called palindromic if it can be read the same forward and backward, for example: 15 ...
分类:
其他好文 时间:
2017-07-17 22:01:38
阅读次数:
179
题目描写叙述 Given a string, determine if it is a palindrome, considering only alphanumeric characters and ignoring cases. For example, “A man, a plan, a ca ...
分类:
编程语言 时间:
2017-07-16 19:28:42
阅读次数:
170
Description 给定k个长度不超过L的01串,求有多少长度为n的01串S满足: 1.该串是回文串 2.该串不存在两个不重叠的子串,在给定的k个串中。 即不存在a<=b<c<=d,S[a,b]是k个串中的一个,S[c,d]是k个串中的一个 (It does not contain two no ...
分类:
其他好文 时间:
2017-07-13 21:56:18
阅读次数:
252
题目 URL:https://leetcode.com/problems/palindrome-number 解法 想办法取出回文数左右两边的数。 首先取右面的数,可以通过“取余”方法取出(LeetCode - 7 - Reverse Integer)。仔细想一下,右面的数取出来了,左面的数自然就呈 ...
分类:
其他好文 时间:
2017-07-12 01:02:00
阅读次数:
159
A palindrome is a symmetrical string, that is, a string read identically from left to right as well as from right to left. You are to write a program ...
分类:
其他好文 时间:
2017-07-06 15:14:53
阅读次数:
211