import java.io.IOException;
import java.util.Scanner;

public class Main {
	public static void main(String[] args) throws IOException {
		Scanner sc = new Scanner(System.in);

		String s = sc.next();

		System.out.println(s.matches("A[a-z]+C[a-z]+") ? "AC" : "WA");

		sc.close();
	}
} import java.io.IOException; IOException java.io import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[] args) throws IOException {
		Scanner sc = new Scanner(System.in);

		String s = sc.next();

		System.out.println(s.matches("A[a-z]+C[a-z]+") ? "AC" : "WA");

		sc.close();
	}
} Main public static void main(String[] args) throws IOException {
		Scanner sc = new Scanner(System.in);

		String s = sc.next();

		System.out.println(s.matches("A[a-z]+C[a-z]+") ? "AC" : "WA");

		sc.close();
	} main {
		Scanner sc = new Scanner(System.in);

		String s = sc.next();

		System.out.println(s.matches("A[a-z]+C[a-z]+") ? "AC" : "WA");

		sc.close();
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String s = sc.next(); s sc.next() sc.next sc System.out.println(s.matches("A[a-z]+C[a-z]+") ? "AC" : "WA") System.out.println System.out System System.out s.matches("A[a-z]+C[a-z]+") ? "AC" : "WA" s.matches("A[a-z]+C[a-z]+") s.matches s "A[a-z]+C[a-z]+" "AC" "WA" sc.close() sc.close sc String[] args args public class Main {
	public static void main(String[] args) throws IOException {
		Scanner sc = new Scanner(System.in);

		String s = sc.next();

		System.out.println(s.matches("A[a-z]+C[a-z]+") ? "AC" : "WA");

		sc.close();
	}
} public class Main {
	public static void main(String[] args) throws IOException {
		Scanner sc = new Scanner(System.in);

		String s = sc.next();

		System.out.println(s.matches("A[a-z]+C[a-z]+") ? "AC" : "WA");

		sc.close();
	}
} Main
import java.io.IOException;
import java.util.Scanner;

public class Main {
	public static void main(String[] args) throws IOException {
		Scanner sc = new Scanner(System.in);

		String s = sc.next();

		System.out.println(s.matches("A[a-z]+C[a-z]+") ? "AC" : "WA");

		sc.close();
	}
}
