最近写什么 WA什么烦死了,于是练练码力,水一水
顺便换个心情换个头像什么的 - -
这道题难点就是找准什么时候用 "automaton" 什么时候 用 "array"(这不是废话吗)
#include <cstdio>
#include <cstring>
using namespace std;
char s[200],t[200];
int main()
{
scanf("%s%s",s,t);
int ls=strlen(s),lt=strlen(t);
int hashs[26]={0},hasht[26]={0};///记录字母用数组
if(lt>ls) ///t>s肯定是变不了的
{
puts("need tree");
return 0;
}
......
阅读全文