首页 > TAG信息列表 > abab

day1

Markdown学习 标题: 三级标题 四级标题 字体 hi abab 分割线 图片 超链接 [点击链接](哔哩哔哩 (゜-゜)つロ 干杯~-bilibili) 列表 a c b a b c 表格 名字 性别 名字 性别 生日 张三 男 1997.1.1 代码 public

typora

标题 加粗 倾斜 高亮 上标上标 下标下标 列表 123 456 789 表格(快捷键ctrl+t) 123112233 分割线 代码框 abab abab 引用 1 2 3

All with Pairs

A. All with Pairs 参考:A. All with Pairs (哈希值+next) 需要用到的东西是字符串哈希和前缀数组。 首先用字符串哈希将每一个后缀都统计一下,并用不同的后缀会映射为不同的哈希值,所以这样就可以在\(O(1)\)的时间复杂度内比较出两个字符串是否一样。 还要考虑到的事情是后缀为 aba

codeforces1316B String Modification

Vasya has a string ss of length nn. He decides to make the following modification to the string: Pick an integer kk, (1≤k≤n1≤k≤n). For ii from 11 to n−k+1n−k+1, reverse the substring s[i:i+k−1]s[i:i+k−1] of ss. For example, if string ss

[kuangbin带你飞]专题十六 KMP & 扩展KMP & ManacherK - Count the string HDU - 3336(前缀数量问题)

K - Count the string HDU - 3336 题目链接:https://vjudge.net/contest/70325#problem/K 题目: It is well known that AekdyCoin is good at string problems as well as number theory problems. When given a string s, we can write down all the non-empty prefixes of this

C中字符串函数的应用

#include <stdio.h> #include <string.h> #define N 80 int fun(char *s, char *t) //求出t字符串在s中占有个数,例如abab和ab,则占有1个 { int n,i; //若是abab和ac,则占有0个 char *p , *r; n=0; i=0; while ( *s ) { p=