Codeforces Beta Round #8 A. Train and Peter KMP 链接:http://codeforces.com/contest/8/problem/A 题意:给了一个文本串,然后现在有两个模式串,问这两个模式串能否正向和反向匹配。 解法:kmp粘粘粘。 //CF 8A #include <bits/stdc++.h> using namespace std; const int maxn = 1e5...
Codeforces Beta Round #8 A. Train and Peter(字符串) A. Train and Peter time limit per test:1 second memory limit per test:64 megabytes Peter likes to travel by train. He likes it so much that on the train he falls asleep. Once in summer Peter was going......