import ru.ifmo.testlib.*;
import ru.ifmo.testlib.Outcome.Type;

public class Check implements Checker {
    @Override
    public Outcome test(InStream inf, InStream ouf, InStream ans) {
        try {
        int n = inf.nextInt();
        for(int i = 0; i < n; i++)
        {
        	int a = ouf.nextInt();
        	int b = ans.nextInt();
        	if(a != b)
        		return new Outcome(Type.WA, "");
        }
        return new Outcome(Type.OK, "");
      } catch (Throwable e) {
            return new Outcome(Type.PE, "Something went wrong!");
      }
    }
}
