摘要: http://codeforces.com/contest/358/problem/B先按照题意说的构造一个字符串s,然后与对比的字符串T比较,看看在字符串T中顺序查找有没有字符串S的所有字符,有输出yes,否则输出no. 1 #include 2 #include 3 #include 4 ... 阅读全文
posted @ 2014-08-25 20:03 null1019 阅读(123) 评论(0) 推荐(0) 编辑
摘要: http://codeforces.com/contest/357/problem/D题意:给你两个数n和m,表示两个字符串的循环次数,然后给出两个字符串,求出其相同位置字符不同的个数。先求出两个字符串长度的最大公约数和最小公倍数,然后求出在最小公倍数范围内的不同字符的个数,后面的和前面的一样,最终... 阅读全文
posted @ 2014-08-25 18:13 null1019 阅读(111) 评论(0) 推荐(0) 编辑
摘要: http://codeforces.com/contest/357/problem/C 1 #include 2 #include 3 #include 4 #define maxn 300010 5 using namespace std; 6 7 int n,m; 8 i... 阅读全文
posted @ 2014-08-25 15:15 null1019 阅读(120) 评论(0) 推荐(0) 编辑
摘要: http://codeforces.com/contest/357/problem/B 1 #include 2 #include 3 #include 4 #define maxn 100010 5 using namespace std; 6 7 int g[maxn][4]; 8 in... 阅读全文
posted @ 2014-08-25 10:21 null1019 阅读(150) 评论(0) 推荐(0) 编辑