import java.util.Arrays;

import ru.ifmo.testlib.Checker;
import ru.ifmo.testlib.InStream;
import ru.ifmo.testlib.Outcome;
import ru.ifmo.testlib.Outcome.Type;
import java.util.*;


public class Check implements Checker {
    @Override
    public Outcome test(InStream inf, InStream ouf, InStream ans) {
        int n = inf.nextInt();
        int k = inf.nextInt();
        inf.nextLine();
        HashMap<Integer, Integer> in = new HashMap<Integer, Integer>();
        for (int i = 0; i < n; i++) {
            Integer now = inf.nextInt();
            if (in.get(now) == null)
                in.put(now, 1);
            else {
                Integer t = (Integer)in.get(now);
                t++;
                in.put(now, t);
            }
        }
        int l = ans.nextInt(), r = 0;
        for (int i = 0; i < k - 1; ++i)
            r = ans.nextInt();
        int answer = r - l;
        int mn = 1000000000, mx = 0;
        for (int i = 0; i < k; i++) {
            int now = ouf.nextInt();
            mn = Math.min(now, mn);
            mx = Math.max(now, mx);
            if (in.get(now) == null || in.get(now).equals((Integer)0)) {
                System.out.println(in.get(now));
                return new Outcome(Type.WA, "icorrect output");
            }
            int t = (Integer)in.get(now);
            t--;
            in.put(now, t);
        }
        
        if (answer == mx - mn)
            return new Outcome(Type.OK, "OK");                  
        return new Outcome(Type.WA, "WA");
    }   
}
