
PAM
coldfresh
那我们开始吧
展开
-
【HDU3948】The Number of Palindromes(PAM)
问题是问本质不同的回文串的个数,回文树的模版题 代码: #include<iostream> #include<cstdio> #include<queue> #include<cstring> #define maxx 100005 #define N 26 using namespace std; typedef long long ll; st...原创 2019-09-12 16:48:48 · 188 阅读 · 0 评论 -
P5496 【模板】回文自动机(PAM)
题目背景 模板题,无背景(其实是我想不出背景)。 题目描述 给定一个字符串 s。保证每个字符为小写字母。对于 s 的每个位置,请求出以该位置结尾的回文子串个数。 这个字符串被进行了加密,除了第一个字符,其他字符都需要通过上一个位置的答案来解密。 具体地,若第 ii(i≥1) 个位置的答案是 k,第 i+1 个字符读入时的 ASCII 码为 c,则第 i+1 个字符实际的 ASCII 码为 (c−9...原创 2019-09-12 19:27:51 · 258 阅读 · 0 评论 -
【2019徐州网络赛 G】Colorful String(PAM)
The value of a string s is equal to the number of different letters which appear in this string. Your task is to calculate the total value of all the palindrome substring. Input The input consists of ...原创 2019-09-12 20:33:56 · 344 阅读 · 0 评论