/*
做本体好杯具, 是数据若还是怎么的
START
1 + 29 = 300
END
START
1 + 29 = 30 0
END
结果是什么?
理论上是WA
但是我的代码是 PE
交上去就却AC了
够晕的 但我看题目也没说不能出现这组情况
还有
START
1 + 2 = 3
END
START
1 + 2 = 3
END
这个结果也让人杯具
*/
#include <iostream>
#include <string>
#include <sstream>
#include <cstring>
#define MAXN 5005
using namespace std;
char corrans[MAXN], mans[MAXN];
string fc, fm;
void result() {
if(fc == fm) {
puts("Accepted");
return ;
}
int i;
string s1 = "", s2 = "";
for(i = 0; i < fc.length(); ++ i) {
if(fc[ i ] != ' ' && fc[ i ] != 9) {
s1 += fc[ i ];
}
}
for(i = 0; i < fm.length(); ++ i) {
if(fm[ i ] != ' ' && fm[ i ] != 9) {
s2 += fm[ i ];
}
}
if(s1 != s2) puts("Wrong Answer");
else puts("Presentation Error");
}
int main() {
int test, i;
scanf("%d%*c", &test);
while(test --) {
fc = "";
while(gets(corrans)) {
if(strcmp("END", corrans) == 0) break;
if(corrans[ 0 ] == 0) fc += " ";
else {
for(i = 0; i < strlen(corrans); ++ i) {
fc += corrans[ i ];
}
}
}
fm = "";
while(gets(mans)) {
if(strcmp("END", mans) == 0) break;
if(mans[ 0 ] == 0) fm += " ";
else {
for(i = 0; i < strlen(mans); ++ i) {
fm += mans[ i ];
}
}
}
result();
}
return 0;
}