- 博客(24)
- 收藏
- 关注
原创 牛客寒假算法基础集训营4 F Applese 的QQ群
牛客寒假算法基础集训营4 F Applese 的QQ群 链接:https://ac.nowcoder.com/acm/contest/330/F来源:牛客网Applese 有一个QQ群。在这个群中,大家互相请教问题。如 b 向 a 请教过问题,就把 a 叫做是 b 的"老板"。这样一个群中就会有很多老板。 同时规定:如果 a 是 b...
2019-01-30 12:25:00 171
原创 牛客寒假算法基础集训营4 I Applese 的回文串
牛客寒假算法基础集训营4 I Applese 的回文串 链接:https://ac.nowcoder.com/acm/contest/330/I来源:牛客网自从 Applese 学会了字符串之后,精通各种字符串算法,比如……判断一个字符串是不是回文串。 这样的题目未免让它觉得太无聊,于是它想到了一个新的问题。 如何判断一个字符串在...
2019-01-29 22:05:00 105
原创 牛客寒假算法基础集训营4 G Applese 的毒气炸弹
牛客寒假算法基础集训营4 G Applese 的毒气炸弹 链接:https://ac.nowcoder.com/acm/contest/330/G来源:牛客网众所周知,Applese 是个很强的选手,它的化学一定很好。 今天他又AK了一套题觉得很无聊,于是想做个毒气炸弹玩。 毒气炸弹需要 k 种不同类型元素构成,Applese一共...
2019-01-29 21:57:00 177
原创 牛客寒假算法基础集训营4 E applese 涂颜色
牛客寒假算法基础集训营4 E applese 涂颜色 链接:https://ac.nowcoder.com/acm/contest/330/E精通程序设计的 Applese 叕写了一个游戏。 在这个游戏中,有一个 n 行 m 列的方阵。现在它要为这个方阵涂上黑白两种颜色。规定左右相邻两格的颜色不能相同。请你帮它统计一下有多少种涂色的...
2019-01-29 21:50:00 114
原创 牛客寒假算法基础集训营4 B applese 走方格
牛客寒假算法基础集训营4 B applese 走方格 链接:https://ac.nowcoder.com/acm/contest/330/B 构造题,但是有两个特判。。。1 22 1 然后就水了,血亏 1 #include<stdio.h> 2 int n,m; 3 int main(...
2019-01-29 21:35:00 94
原创 kuangbin专题十六 KMP&&扩展KMP HDU3613 Best Reward(前缀和+manacher or ekmp)
kuangbin专题十六 KMP&&扩展KMP HDU3613 Best Reward(前缀和+manacher or ekmp) After an uphill battle, General Li won a great victory. Now the head of state decide to reward him w...
2019-01-28 11:33:00 127
原创 kuangbin专题十六 KMP&&扩展KMP HDU3294 Girls' research
kuangbin专题十六 KMP&&扩展KMP HDU3294 Girls' research One day, sailormoon girls are so delighted that they intend to research about palindromic strings. Operation contains ...
2019-01-27 13:52:00 105
原创 kuangbin专题十六 KMP&&扩展KMP HDU3068 最长回文
kuangbin专题十六 KMP&&扩展KMP HDU3068 最长回文 给出一个只由小写英文字符a,b,c...y,z组成的字符串S,求S中最长回文串的长度. 回文就是正反读都是一样的字符串,如aba, abba等 Input输入有多组case,不超过120组,每组输入为一行小写英文字符a,b,c...y,z组成的字符串...
2019-01-27 00:15:00 120
原创 kuangbin专题十六 KMP&&扩展KMP HDU3347 String Problem(最小最大表示法+kmp)
kuangbin专题十六 KMP&&扩展KMP HDU3347 String Problem(最小最大表示法+kmp) Give you a string with length N, you can generate N strings by left shifts. For example let consider the ...
2019-01-25 21:47:00 93
原创 kuangbin专题十六 KMP&&扩展KMP HDU2609 How many (最小字符串表示法)
kuangbin专题十六 KMP&&扩展KMP HDU2609 How many (最小字符串表示法) Give you n ( n < 10000) necklaces ,the length of necklace will not large than 100,tell me How many kinds of nec...
2019-01-25 17:11:00 95
原创 牛客寒假算法基础集训营1 D 小a与黄金街道
牛客寒假算法基础集训营1 D 小a与黄金街道 链接:https://ac.nowcoder.com/acm/contest/317/D首先被数学题吓到了。gcd(n,x)==1 那么必定有 gcd(n,n-x)==1 证明略。并且两个人的对答案贡献一样。 对于A来说 ,A*ka *k(n-a) * kb *k(n-b) = A*kRn...
2019-01-25 15:07:00 87
原创 kuangbin专题十六 KMP&&扩展KMP HDU2328 Corporate Identity
kuangbin专题十六 KMP&&扩展KMP HDU2328 Corporate Identity Beside other services, ACM helps companies to clearly state their “corporate identity”, which includes company logo...
2019-01-21 21:27:00 138
原创 kuangbin专题十六 KMP&&扩展KMP HDU1238 Substrings
kuangbin专题十六 KMP&&扩展KMP HDU1238 Substrings You are given a number of case-sensitive strings of alphabetic characters, find the largest string X, such that either X, o...
2019-01-21 17:18:00 141
原创 kuangbin专题十六 KMP&&扩展KMP HDU4300 Clairewd’s message
kuangbin专题十六 KMP&&扩展KMP HDU4300 Clairewd’s message Clairewd is a member of FBI. After several years concealing in BUPT, she intercepted some important messages and sh...
2019-01-21 16:10:00 107
原创 kuangbin专题十六 KMP&&扩展KMP HDU3336 Count the string
kuangbin专题十六 KMP&&扩展KMP HDU3336 Count the string It is well known that AekdyCoin is good at string problems as well as number theory problems. When given a string s, ...
2019-01-21 14:22:00 118
原创 kuangbin专题十六 KMP&&扩展KMP POJ3080 Blue Jeans
kuangbin专题十六 KMP&&扩展KMP POJ3080 Blue Jeans The Genographic Project is a research partnership between IBM and The National Geographic Society that is analyzing DNA f...
2019-01-18 23:19:00 132
原创 kuangbin专题十六 KMP&&扩展KMP HDU2594 Simpsons’ Hidden Talents
kuangbin专题十六 KMP&&扩展KMP HDU2594 Simpsons’ Hidden Talents Homer: Marge, I just figured out a way to discover some of the talents we weren’t aware we had. Marge: Yeah, ...
2019-01-14 21:18:00 119
原创 kuangbin专题十六 KMP&&扩展KMP POJ2752 Seek the Name, Seek the Fame
kuangbin专题十六 KMP&&扩展KMP POJ2752 Seek the Name, Seek the Fame The little cat is so famous, that many couples tramp over hill and dale to Byteland, and asked the litt...
2019-01-14 19:27:00 78
原创 kuangbin专题十六 KMP&&扩展KMP POJ2406 Power Strings
kuangbin专题十六 KMP&&扩展KMP POJ2406 Power Strings Given two strings a and b we define a*b to be their concatenation. For example, if a = "abc" and b = "def" then a*b = ...
2019-01-14 15:39:00 114
原创 kuangbin专题十六 KMP&&扩展KMP HDU1358 Period
kuangbin专题十六 KMP&&扩展KMP HDU1358 Period For each prefix of a given string S with N characters (each character has an ASCII code between 97 and 126, inclusive), we want...
2019-01-14 13:47:00 82
原创 kuangbin专题十六 KMP&&扩展KMP HDU3746 Cyclic Nacklace
kuangbin专题十六 KMP&&扩展KMP HDU3746 Cyclic Nacklace CC always becomes very depressed at the end of this month, he has checked his credit card yesterday, without any surpr...
2019-01-14 12:01:00 126
原创 kuangbin专题十六 KMP&&扩展KMP HDU2087 剪花布条
kuangbin专题十六 KMP&&扩展KMP HDU2087 剪花布条 一块花布条,里面有些图案,另有一块直接可用的小饰条,里面也有一些图案。对于给定的花布条和小饰条,计算一下能从花布条中尽可能剪出几块小饰条来呢? Input输入中含有一些数据,分别是成对出现的花布条和小饰条,其布条都是用可见ASCII字符表示的,可见...
2019-01-13 20:21:00 85
原创 kuangbin专题十六 KMP&&扩展KMP HDU1686 Oulipo
kuangbin专题十六 KMP&&扩展KMP HDU1686 Oulipo The French author Georges Perec (1936–1982) once wrote a book, La disparition, without the letter 'e'. He was a member of the O...
2019-01-13 18:06:00 73
原创 kuangbin专题十六 KMP&&扩展KMP HDU1711 Number Sequence
kuangbin专题十六 KMP&&扩展KMP HDU1711 Number Sequence Given two sequences of numbers : a[1], a[2], ...... , a[N], and b[1], b[2], ...... , b[M] (1 <= M <= 10000, 1 &l...
2019-01-13 17:39:00 79
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人