import java.io.*;
import java.math.*;
import java.util.*;

public class Main {
    private static boolean debug = false;
    private static boolean elapsed = false;

    private static PrintWriter _out = new PrintWriter(System.out);
    private static PrintWriter _err = new PrintWriter(System.err);

    private static final int INF = Integer.MAX_VALUE / 2;

    private void solve(Scanner sc) {
        String s = sc.nextLine();
        if (s.matches("\\AA[a-z]+C[a-z]+\\z")) {
            _out.println("AC");
        } else {
            _out.println("WA");
        }
    }
    private static BigInteger C(long n, long r) {
        BigInteger res = BigInteger.ONE;
        for (long i = n; i > n - r; --i) {
            res = res.multiply(BigInteger.valueOf(i));
        }
        for (long i = r; i > 1; --i) {
            res = res.divide(BigInteger.valueOf(i));
        }
        return res;
    }
    private static BigInteger P(long n, long r) {
        BigInteger res = BigInteger.ONE;
        for (long i = n; i > n - r; --i) {
            res = res.multiply(BigInteger.valueOf(i));
        }
        return res;
    }
    /*
     * 10^10 > Integer.MAX_VALUE = 2147483647 > 10^9
     * 10^19 > Long.MAX_VALUE = 9223372036854775807L > 10^18
     */
    public static void main(String[] args) {
        long S = System.currentTimeMillis();

        Scanner sc = new Scanner(System.in);
        new Main().solve(sc);
        _out.flush();

        long G = System.currentTimeMillis();
        if (elapsed) {
            _err.println((G - S) + "ms");
        }
        _err.flush();
    }
} import java.io.*; io.* java import java.math.*; math.* java import java.util.*; util.* java public class Main {
    private static boolean debug = false;
    private static boolean elapsed = false;

    private static PrintWriter _out = new PrintWriter(System.out);
    private static PrintWriter _err = new PrintWriter(System.err);

    private static final int INF = Integer.MAX_VALUE / 2;

    private void solve(Scanner sc) {
        String s = sc.nextLine();
        if (s.matches("\\AA[a-z]+C[a-z]+\\z")) {
            _out.println("AC");
        } else {
            _out.println("WA");
        }
    }
    private static BigInteger C(long n, long r) {
        BigInteger res = BigInteger.ONE;
        for (long i = n; i > n - r; --i) {
            res = res.multiply(BigInteger.valueOf(i));
        }
        for (long i = r; i > 1; --i) {
            res = res.divide(BigInteger.valueOf(i));
        }
        return res;
    }
    private static BigInteger P(long n, long r) {
        BigInteger res = BigInteger.ONE;
        for (long i = n; i > n - r; --i) {
            res = res.multiply(BigInteger.valueOf(i));
        }
        return res;
    }
    /*
     * 10^10 > Integer.MAX_VALUE = 2147483647 > 10^9
     * 10^19 > Long.MAX_VALUE = 9223372036854775807L > 10^18
     */
    public static void main(String[] args) {
        long S = System.currentTimeMillis();

        Scanner sc = new Scanner(System.in);
        new Main().solve(sc);
        _out.flush();

        long G = System.currentTimeMillis();
        if (elapsed) {
            _err.println((G - S) + "ms");
        }
        _err.flush();
    }
} Main private static boolean debug = false; debug false private static boolean elapsed = false; elapsed false private static PrintWriter _out = new PrintWriter(System.out); _out new PrintWriter(System.out) private static PrintWriter _err = new PrintWriter(System.err); _err new PrintWriter(System.err) private static final int INF = Integer.MAX_VALUE / 2; INF Integer.MAX_VALUE / 2 Integer.MAX_VALUE Integer Integer.MAX_VALUE 2 private void solve(Scanner sc) {
        String s = sc.nextLine();
        if (s.matches("\\AA[a-z]+C[a-z]+\\z")) {
            _out.println("AC");
        } else {
            _out.println("WA");
        }
    } solve {
        String s = sc.nextLine();
        if (s.matches("\\AA[a-z]+C[a-z]+\\z")) {
            _out.println("AC");
        } else {
            _out.println("WA");
        }
    } String s = sc.nextLine(); s sc.nextLine() sc.nextLine sc if (s.matches("\\AA[a-z]+C[a-z]+\\z")) {
            _out.println("AC");
        } else {
            _out.println("WA");
        } s.matches("\\AA[a-z]+C[a-z]+\\z") s.matches s "\\AA[a-z]+C[a-z]+\\z" {
            _out.println("AC");
        } _out.println("AC") _out.println _out "AC" {
            _out.println("WA");
        } _out.println("WA") _out.println _out "WA" Scanner sc sc private static BigInteger C(long n, long r) {
        BigInteger res = BigInteger.ONE;
        for (long i = n; i > n - r; --i) {
            res = res.multiply(BigInteger.valueOf(i));
        }
        for (long i = r; i > 1; --i) {
            res = res.divide(BigInteger.valueOf(i));
        }
        return res;
    } C {
        BigInteger res = BigInteger.ONE;
        for (long i = n; i > n - r; --i) {
            res = res.multiply(BigInteger.valueOf(i));
        }
        for (long i = r; i > 1; --i) {
            res = res.divide(BigInteger.valueOf(i));
        }
        return res;
    } BigInteger res = BigInteger.ONE; res BigInteger.ONE BigInteger BigInteger.ONE for (long i = n; i > n - r; --i) {
            res = res.multiply(BigInteger.valueOf(i));
        } long i = n; long i = n; i n i > n - r i n - r n r --i --i i {
            res = res.multiply(BigInteger.valueOf(i));
        } {
            res = res.multiply(BigInteger.valueOf(i));
        } res = res.multiply(BigInteger.valueOf(i)) res res.multiply(BigInteger.valueOf(i)) res.multiply res BigInteger.valueOf(i) BigInteger.valueOf BigInteger i for (long i = r; i > 1; --i) {
            res = res.divide(BigInteger.valueOf(i));
        } long i = r; long i = r; i r i > 1 i 1 --i --i i {
            res = res.divide(BigInteger.valueOf(i));
        } {
            res = res.divide(BigInteger.valueOf(i));
        } res = res.divide(BigInteger.valueOf(i)) res res.divide(BigInteger.valueOf(i)) res.divide res BigInteger.valueOf(i) BigInteger.valueOf BigInteger i return res; res long n n long r r private static BigInteger P(long n, long r) {
        BigInteger res = BigInteger.ONE;
        for (long i = n; i > n - r; --i) {
            res = res.multiply(BigInteger.valueOf(i));
        }
        return res;
    } P {
        BigInteger res = BigInteger.ONE;
        for (long i = n; i > n - r; --i) {
            res = res.multiply(BigInteger.valueOf(i));
        }
        return res;
    } BigInteger res = BigInteger.ONE; res BigInteger.ONE BigInteger BigInteger.ONE for (long i = n; i > n - r; --i) {
            res = res.multiply(BigInteger.valueOf(i));
        } long i = n; long i = n; i n i > n - r i n - r n r --i --i i {
            res = res.multiply(BigInteger.valueOf(i));
        } {
            res = res.multiply(BigInteger.valueOf(i));
        } res = res.multiply(BigInteger.valueOf(i)) res res.multiply(BigInteger.valueOf(i)) res.multiply res BigInteger.valueOf(i) BigInteger.valueOf BigInteger i return res; res long n n long r r /*
     * 10^10 > Integer.MAX_VALUE = 2147483647 > 10^9
     * 10^19 > Long.MAX_VALUE = 9223372036854775807L > 10^18
     */
    public static void main(String[] args) {
        long S = System.currentTimeMillis();

        Scanner sc = new Scanner(System.in);
        new Main().solve(sc);
        _out.flush();

        long G = System.currentTimeMillis();
        if (elapsed) {
            _err.println((G - S) + "ms");
        }
        _err.flush();
    } main {
        long S = System.currentTimeMillis();

        Scanner sc = new Scanner(System.in);
        new Main().solve(sc);
        _out.flush();

        long G = System.currentTimeMillis();
        if (elapsed) {
            _err.println((G - S) + "ms");
        }
        _err.flush();
    } long S = System.currentTimeMillis(); S System.currentTimeMillis() System.currentTimeMillis System Scanner sc = new Scanner(System.in); sc new Scanner(System.in) new Main().solve(sc) new Main().solve new Main() sc _out.flush() _out.flush _out long G = System.currentTimeMillis(); G System.currentTimeMillis() System.currentTimeMillis System if (elapsed) {
            _err.println((G - S) + "ms");
        } elapsed {
            _err.println((G - S) + "ms");
        } _err.println((G - S) + "ms") _err.println _err (G - S) + "ms" (G - S) G S "ms" _err.flush() _err.flush _err String[] args args public class Main {
    private static boolean debug = false;
    private static boolean elapsed = false;

    private static PrintWriter _out = new PrintWriter(System.out);
    private static PrintWriter _err = new PrintWriter(System.err);

    private static final int INF = Integer.MAX_VALUE / 2;

    private void solve(Scanner sc) {
        String s = sc.nextLine();
        if (s.matches("\\AA[a-z]+C[a-z]+\\z")) {
            _out.println("AC");
        } else {
            _out.println("WA");
        }
    }
    private static BigInteger C(long n, long r) {
        BigInteger res = BigInteger.ONE;
        for (long i = n; i > n - r; --i) {
            res = res.multiply(BigInteger.valueOf(i));
        }
        for (long i = r; i > 1; --i) {
            res = res.divide(BigInteger.valueOf(i));
        }
        return res;
    }
    private static BigInteger P(long n, long r) {
        BigInteger res = BigInteger.ONE;
        for (long i = n; i > n - r; --i) {
            res = res.multiply(BigInteger.valueOf(i));
        }
        return res;
    }
    /*
     * 10^10 > Integer.MAX_VALUE = 2147483647 > 10^9
     * 10^19 > Long.MAX_VALUE = 9223372036854775807L > 10^18
     */
    public static void main(String[] args) {
        long S = System.currentTimeMillis();

        Scanner sc = new Scanner(System.in);
        new Main().solve(sc);
        _out.flush();

        long G = System.currentTimeMillis();
        if (elapsed) {
            _err.println((G - S) + "ms");
        }
        _err.flush();
    }
} public class Main {
    private static boolean debug = false;
    private static boolean elapsed = false;

    private static PrintWriter _out = new PrintWriter(System.out);
    private static PrintWriter _err = new PrintWriter(System.err);

    private static final int INF = Integer.MAX_VALUE / 2;

    private void solve(Scanner sc) {
        String s = sc.nextLine();
        if (s.matches("\\AA[a-z]+C[a-z]+\\z")) {
            _out.println("AC");
        } else {
            _out.println("WA");
        }
    }
    private static BigInteger C(long n, long r) {
        BigInteger res = BigInteger.ONE;
        for (long i = n; i > n - r; --i) {
            res = res.multiply(BigInteger.valueOf(i));
        }
        for (long i = r; i > 1; --i) {
            res = res.divide(BigInteger.valueOf(i));
        }
        return res;
    }
    private static BigInteger P(long n, long r) {
        BigInteger res = BigInteger.ONE;
        for (long i = n; i > n - r; --i) {
            res = res.multiply(BigInteger.valueOf(i));
        }
        return res;
    }
    /*
     * 10^10 > Integer.MAX_VALUE = 2147483647 > 10^9
     * 10^19 > Long.MAX_VALUE = 9223372036854775807L > 10^18
     */
    public static void main(String[] args) {
        long S = System.currentTimeMillis();

        Scanner sc = new Scanner(System.in);
        new Main().solve(sc);
        _out.flush();

        long G = System.currentTimeMillis();
        if (elapsed) {
            _err.println((G - S) + "ms");
        }
        _err.flush();
    }
} Main
import java.io.*;
import java.math.*;
import java.util.*;

public class Main {
    private static boolean debug = false;
    private static boolean elapsed = false;

    private static PrintWriter _out = new PrintWriter(System.out);
    private static PrintWriter _err = new PrintWriter(System.err);

    private static final int INF = Integer.MAX_VALUE / 2;

    private void solve(Scanner sc) {
        String s = sc.nextLine();
        if (s.matches("\\AA[a-z]+C[a-z]+\\z")) {
            _out.println("AC");
        } else {
            _out.println("WA");
        }
    }
    private static BigInteger C(long n, long r) {
        BigInteger res = BigInteger.ONE;
        for (long i = n; i > n - r; --i) {
            res = res.multiply(BigInteger.valueOf(i));
        }
        for (long i = r; i > 1; --i) {
            res = res.divide(BigInteger.valueOf(i));
        }
        return res;
    }
    private static BigInteger P(long n, long r) {
        BigInteger res = BigInteger.ONE;
        for (long i = n; i > n - r; --i) {
            res = res.multiply(BigInteger.valueOf(i));
        }
        return res;
    }
    /*
     * 10^10 > Integer.MAX_VALUE = 2147483647 > 10^9
     * 10^19 > Long.MAX_VALUE = 9223372036854775807L > 10^18
     */
    public static void main(String[] args) {
        long S = System.currentTimeMillis();

        Scanner sc = new Scanner(System.in);
        new Main().solve(sc);
        _out.flush();

        long G = System.currentTimeMillis();
        if (elapsed) {
            _err.println((G - S) + "ms");
        }
        _err.flush();
    }
}