
------------------字符串
文章平均质量分 76
dxyinme
这个作者很懒,什么都没留下…
展开
-
[hdu6230]Palindrome
Time Limit: 6000/3000 MS (Java/Others)Memory Limit: 262144/262144 K (Java/Others)Problem DescriptionAlice like strings, especially long strings. For each string, she has a special evaluation system...原创 2019-10-13 22:01:10 · 206 阅读 · 0 评论 -
[codeforces923D]Picking Strings
time limit per test : 2 secondsmemory limit per test : 256 megabytesAlice has a string consisting of characters ′A′'A'′A′, ′B′'B'′B′ and ′C′'C'′...原创 2019-05-01 09:16:56 · 365 阅读 · 0 评论 -
[codeforces936C]Lock Puzzle
time limit per test : 2 secondsmemory limit per test : 256 megabytesWelcome to another task about breaking the code lock! Explorers Whitfield and Martin came across an unusual safe, inside of wh...原创 2019-05-01 12:05:44 · 294 阅读 · 0 评论 -
[hdu1251]统计难题
Time Limit: 4000/2000 MS (Java/Others)Memory Limit: 131070/65535 K (Java/Others)Problem DescriptionIgnatius最近遇到一个难题,老师交给他很多单词(只有小写字母组成,不会有重复的单词出现),现在老师要他统计出以某个字符串为前缀的单词数量(单词本身也是自己的前缀).Input输入数据的第...原创 2019-05-25 00:02:39 · 124 阅读 · 0 评论 -
[2019牛客多校训练第6场]Palindrome Mouse
链接:https://ac.nowcoder.com/acm/contest/886/C来源:牛客网时间限制:C/C++ 1秒,其他语言2秒空间限制:C/C++ 262144K,其他语言524288K分数:2800题目描述Doctor has a string sss consisting of only lowercase letters. Doctor has got the se...原创 2019-08-04 09:35:53 · 172 阅读 · 0 评论 -
[hdu6599]I Love Palindrome String
Time Limit: 4000/2000 MS (Java/Others)Memory Limit: 131072/131072 K (Java/Others)Problem DescriptionYou are given a string S=s1s2..s∣S∣S=s_1s_2..s_{|S|}S=s1s2..s∣S∣ containing only lowercase Eng...原创 2019-07-26 14:27:52 · 208 阅读 · 0 评论 -
[ACM-ICPC 2018 南京赛区网络预赛]Skr
地址:https://nanti.jisuanke.com/t/A1955A number is skr, if and only if it’s unchanged after being reversed. For example, “12321”, “11” and “1” are skr numbers, but “123”, “221” are not. FYW has a strin...原创 2019-07-26 16:05:46 · 183 阅读 · 0 评论 -
[BZOJ3676][Apio2014]回文串
Time Limit: 20 SecMemory Limit: 128 MBDescription考虑一个只包含小写拉丁字母的字符串sss。我们定义sss的一个子串ttt的“出现值”为t在s中的出现次数乘以t的长度。请你求出sss的所有回文子串中的最大出现值。Input输入只有一行,为一个只包含小写字母(a−z)(a -z)(a−z)的非空字符串sss。Output输出一个整数,为逝...原创 2019-07-26 17:31:13 · 132 阅读 · 0 评论 -
[hdu5421]Victor and String
Time Limit: 2000/1000 MS (Java/Others)Memory Limit: 524288/262144 K (Java/Others)Victor loves to play with string. He thinks a string is charming as the string is a palindromic string.Victor wants ...原创 2019-07-27 09:52:10 · 189 阅读 · 0 评论 -
[codeforces906E]Reverses
time limit per test : 2 secondsmemory limit per test : 256 megabytes分数:3200Hurricane came to Berland and to suburbs Stringsvill. You are going to it to check if it’s all right with you favorite str...原创 2019-08-18 10:10:12 · 213 阅读 · 0 评论 -
[codeforces1200E]Compress Words
time limit per test : 1 secondmemory limit per test : 256 megabytes分数:2000,但是我觉得这个题挺神的。Amugae has a sentence consisting of nnn words. He want to compress this sentence into one word. Amugae doesn’t...原创 2019-09-11 18:06:04 · 408 阅读 · 0 评论 -
[codeforces1202E]You Are Given Some Strings...
time limit per test : 3 secondsmemory limit per test : 256 megabytes分数:2500You are given a string t and n strings s1,s2,…,sns_1,s_2,…,s_ns1,s2,…,sn. All strings consist of lowercase Latin letter...原创 2019-09-13 16:46:39 · 704 阅读 · 0 评论 -
[codeforces965E]Short Code
time limit per test : 1 secondmemory limit per test : 256 megabytesArkady’s code contains nnn variables. Each variable has a unique name consisting of lowercase English letters only. One day Ark...原创 2019-05-03 10:12:31 · 284 阅读 · 0 评论 -
Educational Codeforces Round 16
抽空做了一下这些题。。。F题真的是不会了。。。A. King MovesThe only king stands on the standard chess board. You are given his position in format “cd”, where c is the column from ‘a’ to ‘h’ and d is the row from ‘1’ to ‘8’.原创 2016-08-28 14:16:00 · 417 阅读 · 0 评论 -
[HDU3068]最长回文
Problem Description给出一个只由小写英文字符a,b,c…y,z组成的字符串S,求S中最长回文串的长度. 回文就是正反读都是一样的字符串,如aba, abba等Input输入有多组case,不超过120组,每组输入为一行小写英文字符a,b,c…y,z组成的字符串S 两组case之间由空行隔开(该空行不用处理) 字符串长度len Output每一行一个整原创 2018-01-05 17:06:48 · 189 阅读 · 0 评论 -
[HDU2222]Keywords Search
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 131072/131072 K (Java/Others)Problem DescriptionIn the modern time, Search engine came into the life of everybody like Google, Baidu, etc.原创 2018-01-20 20:53:17 · 302 阅读 · 0 评论 -
[UESTC1582]奇迹的魔法啊,再度出现!
Time Limit: 3000/1000MS (Java/Others) Memory Limit: 131072/131072KB (Java/Others) 想对你说的话,如山似海。——AsahinaMirai 决战之后,魔法界和无魔法界分离,为了和Riko再次相见,Mirai必须用经受考验,唤醒奇迹的魔法。那考验就是——出现了n个非负整数a1,a2,…,an, 对于m次询问,...原创 2018-03-02 23:39:46 · 188 阅读 · 0 评论 -
AtCoder Regular Contest 097
因为太菜了所以只有前两题>_<C. 题意:给定一个|S|<=5000|S|<=5000|S|SSS,求它的所有子串(不重复)中第k小的(k<=5)(k<=5)(kSSS的所有长度小于等于5的子串然后排序取第k个就好了,时间复杂度也不大OwO#include&am原创 2018-05-13 00:07:16 · 189 阅读 · 0 评论 -
Manacher算法学习
注意事项: 1.manacher只适用于长度为奇数的序列 2.为了回避情况1,我们用其他字符填充原来的字符串让他变成长度为奇数的串 例如: 原串:aabbcabacca变换之后#a#a#b#b#c#a#b##a#c#c#a#设原串为sr,变换后的串为s求sr的最长回文int manacher(){ for(int i=0;i<=(11000...原创 2018-07-25 11:06:03 · 141 阅读 · 0 评论 -
AC自动机的基本操作
1.询问在文本串中各个询问串各出现了几次 hdu3065#include<cstdio>#include<cstring>#include<algorithm>#include<iostream>#include<cmath>#include<queue>#include<cstdlib>#de原创 2018-08-28 15:18:59 · 374 阅读 · 0 评论 -
[HDU5918]Sequence I
Time Limit: 3000/1500 MS (Java/Others)Memory Limit: 65536/65536 K (Java/Others)Problem DescriptionMr. Frog has two sequences a1,a2,⋯,ana_1,a_2,⋯,a_na1,a2,⋯,an and b1,b2,⋯,bmb_1,b_2,⋯,b_mb1,b2,...原创 2018-10-12 11:21:13 · 246 阅读 · 0 评论 -
[HDU6208]The Dominator of Strings
Time Limit: 3000/3000 MS (Java/Others)Memory Limit: 65535/32768 K (Java/Others)Problem DescriptionHere you have a set of strings. AAA dominator is a string of the set dominating all strings else. T...原创 2018-10-07 22:08:47 · 164 阅读 · 0 评论 -
[BZOJ3238][Ahoi2013]差异
Time Limit: 20 SecMemory Limit: 512 MBDescriptionInput一行,一个字符串SOutput一行,一个整数,表示所求值Sample InputcacaoSample Output54HINT2&lt;=N&lt;=5000002&lt;=N&lt;=5000002<=N<=500...原创 2018-11-02 01:51:26 · 225 阅读 · 0 评论 -
[codeforces1070H]BerOS File Suggestion
time limit per test : 3 secondsmemory limit per test : 256 megabytesPolycarp is working on a new operating system called BerOS. He asks you to help with implementation of a file suggestion feature....原创 2018-11-19 21:14:54 · 260 阅读 · 0 评论 -
[HDU2609]How many
Time Limit: 2000/1000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Problem DescriptionGive you n(n&lt;10000)n ( n &lt; 10000)n(n<10000) necklaces ,the length of necklace will...原创 2019-03-10 18:45:34 · 107 阅读 · 0 评论 -
[codeforces]514C
C. Watto and Mechanism time limit per test:3 seconds memory limit per test:256 megabytesWatto, the owner of a spare parts store, has recently got an order for the mechanism that can process strings i原创 2017-12-01 18:39:38 · 444 阅读 · 0 评论