import java.util.*;

public class Main {
	public static void main(String[] args) {
	    Scanner sc = new Scanner(System.in);
        String str = sc.next();
        if(str.matches("A[a-z]+C[a-z]+")) {
            System.out.println("AC");
        } else {
            System.out.println("WA");
        }
    }
} import java.util.*; util.* java public class Main {
	public static void main(String[] args) {
	    Scanner sc = new Scanner(System.in);
        String str = sc.next();
        if(str.matches("A[a-z]+C[a-z]+")) {
            System.out.println("AC");
        } else {
            System.out.println("WA");
        }
    }
} Main public static void main(String[] args) {
	    Scanner sc = new Scanner(System.in);
        String str = sc.next();
        if(str.matches("A[a-z]+C[a-z]+")) {
            System.out.println("AC");
        } else {
            System.out.println("WA");
        }
    } main {
	    Scanner sc = new Scanner(System.in);
        String str = sc.next();
        if(str.matches("A[a-z]+C[a-z]+")) {
            System.out.println("AC");
        } else {
            System.out.println("WA");
        }
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String str = sc.next(); str sc.next() sc.next sc if(str.matches("A[a-z]+C[a-z]+")) {
            System.out.println("AC");
        } else {
            System.out.println("WA");
        } str.matches("A[a-z]+C[a-z]+") str.matches str "A[a-z]+C[a-z]+" {
            System.out.println("AC");
        } System.out.println("AC") System.out.println System.out System System.out "AC" {
            System.out.println("WA");
        } System.out.println("WA") System.out.println System.out System System.out "WA" String[] args args public class Main {
	public static void main(String[] args) {
	    Scanner sc = new Scanner(System.in);
        String str = sc.next();
        if(str.matches("A[a-z]+C[a-z]+")) {
            System.out.println("AC");
        } else {
            System.out.println("WA");
        }
    }
} public class Main {
	public static void main(String[] args) {
	    Scanner sc = new Scanner(System.in);
        String str = sc.next();
        if(str.matches("A[a-z]+C[a-z]+")) {
            System.out.println("AC");
        } else {
            System.out.println("WA");
        }
    }
} Main
import java.util.*;

public class Main {
	public static void main(String[] args) {
	    Scanner sc = new Scanner(System.in);
        String str = sc.next();
        if(str.matches("A[a-z]+C[a-z]+")) {
            System.out.println("AC");
        } else {
            System.out.println("WA");
        }
    }
}