import java.util.*;

public class Main {

	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		String s = sc.next();
		if (s.charAt(0) != 'A') {
			System.out.println("WA");
			return;
		}
		int count = 0;
		for (int i = 2; i < s.length() - 1; i++) {
			if (s.charAt(i) == 'C') {
				count++;
			}
		}
		if (count != 1) {
			System.out.println("WA");
			return;
		}
		count = 0;
		for (int i = 0; i < s.length(); i++) {
			if (s.charAt(i) < 'a' || s.charAt(i) > 'z') {
				count++;
			}
		}
		if (count != 2) {
			System.out.println("WA");
		} else {
			System.out.println("AC");
		}
	}
} import java.util.*; util.* java public class Main {

	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		String s = sc.next();
		if (s.charAt(0) != 'A') {
			System.out.println("WA");
			return;
		}
		int count = 0;
		for (int i = 2; i < s.length() - 1; i++) {
			if (s.charAt(i) == 'C') {
				count++;
			}
		}
		if (count != 1) {
			System.out.println("WA");
			return;
		}
		count = 0;
		for (int i = 0; i < s.length(); i++) {
			if (s.charAt(i) < 'a' || s.charAt(i) > 'z') {
				count++;
			}
		}
		if (count != 2) {
			System.out.println("WA");
		} else {
			System.out.println("AC");
		}
	}
} Main public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		String s = sc.next();
		if (s.charAt(0) != 'A') {
			System.out.println("WA");
			return;
		}
		int count = 0;
		for (int i = 2; i < s.length() - 1; i++) {
			if (s.charAt(i) == 'C') {
				count++;
			}
		}
		if (count != 1) {
			System.out.println("WA");
			return;
		}
		count = 0;
		for (int i = 0; i < s.length(); i++) {
			if (s.charAt(i) < 'a' || s.charAt(i) > 'z') {
				count++;
			}
		}
		if (count != 2) {
			System.out.println("WA");
		} else {
			System.out.println("AC");
		}
	} main {
		Scanner sc = new Scanner(System.in);
		String s = sc.next();
		if (s.charAt(0) != 'A') {
			System.out.println("WA");
			return;
		}
		int count = 0;
		for (int i = 2; i < s.length() - 1; i++) {
			if (s.charAt(i) == 'C') {
				count++;
			}
		}
		if (count != 1) {
			System.out.println("WA");
			return;
		}
		count = 0;
		for (int i = 0; i < s.length(); i++) {
			if (s.charAt(i) < 'a' || s.charAt(i) > 'z') {
				count++;
			}
		}
		if (count != 2) {
			System.out.println("WA");
		} else {
			System.out.println("AC");
		}
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String s = sc.next(); s sc.next() sc.next sc if (s.charAt(0) != 'A') {
			System.out.println("WA");
			return;
		} s.charAt(0) != 'A' s.charAt(0) s.charAt s 0 'A' {
			System.out.println("WA");
			return;
		} System.out.println("WA") System.out.println System.out System System.out "WA" return; int count = 0; count 0 for (int i = 2; i < s.length() - 1; i++) {
			if (s.charAt(i) == 'C') {
				count++;
			}
		} int i = 2; int i = 2; i 2 i < s.length() - 1 i s.length() - 1 s.length() s.length s 1 i++ i++ i {
			if (s.charAt(i) == 'C') {
				count++;
			}
		} {
			if (s.charAt(i) == 'C') {
				count++;
			}
		} if (s.charAt(i) == 'C') {
				count++;
			} s.charAt(i) == 'C' s.charAt(i) s.charAt s i 'C' {
				count++;
			} count++ count if (count != 1) {
			System.out.println("WA");
			return;
		} count != 1 count 1 {
			System.out.println("WA");
			return;
		} System.out.println("WA") System.out.println System.out System System.out "WA" return; count = 0 count 0 for (int i = 0; i < s.length(); i++) {
			if (s.charAt(i) < 'a' || s.charAt(i) > 'z') {
				count++;
			}
		} int i = 0; int i = 0; i 0 i < s.length() i s.length() s.length s i++ i++ i {
			if (s.charAt(i) < 'a' || s.charAt(i) > 'z') {
				count++;
			}
		} {
			if (s.charAt(i) < 'a' || s.charAt(i) > 'z') {
				count++;
			}
		} if (s.charAt(i) < 'a' || s.charAt(i) > 'z') {
				count++;
			} s.charAt(i) < 'a' || s.charAt(i) > 'z' s.charAt(i) < 'a' s.charAt(i) s.charAt s i 'a' s.charAt(i) > 'z' s.charAt(i) s.charAt s i 'z' {
				count++;
			} count++ count if (count != 2) {
			System.out.println("WA");
		} else {
			System.out.println("AC");
		} count != 2 count 2 {
			System.out.println("WA");
		} System.out.println("WA") System.out.println System.out System System.out "WA" {
			System.out.println("AC");
		} System.out.println("AC") System.out.println System.out System System.out "AC" String[] args args public class Main {

	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		String s = sc.next();
		if (s.charAt(0) != 'A') {
			System.out.println("WA");
			return;
		}
		int count = 0;
		for (int i = 2; i < s.length() - 1; i++) {
			if (s.charAt(i) == 'C') {
				count++;
			}
		}
		if (count != 1) {
			System.out.println("WA");
			return;
		}
		count = 0;
		for (int i = 0; i < s.length(); i++) {
			if (s.charAt(i) < 'a' || s.charAt(i) > 'z') {
				count++;
			}
		}
		if (count != 2) {
			System.out.println("WA");
		} else {
			System.out.println("AC");
		}
	}
} public class Main {

	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		String s = sc.next();
		if (s.charAt(0) != 'A') {
			System.out.println("WA");
			return;
		}
		int count = 0;
		for (int i = 2; i < s.length() - 1; i++) {
			if (s.charAt(i) == 'C') {
				count++;
			}
		}
		if (count != 1) {
			System.out.println("WA");
			return;
		}
		count = 0;
		for (int i = 0; i < s.length(); i++) {
			if (s.charAt(i) < 'a' || s.charAt(i) > 'z') {
				count++;
			}
		}
		if (count != 2) {
			System.out.println("WA");
		} else {
			System.out.println("AC");
		}
	}
} Main
import java.util.*;

public class Main {

	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		String s = sc.next();
		if (s.charAt(0) != 'A') {
			System.out.println("WA");
			return;
		}
		int count = 0;
		for (int i = 2; i < s.length() - 1; i++) {
			if (s.charAt(i) == 'C') {
				count++;
			}
		}
		if (count != 1) {
			System.out.println("WA");
			return;
		}
		count = 0;
		for (int i = 0; i < s.length(); i++) {
			if (s.charAt(i) < 'a' || s.charAt(i) > 'z') {
				count++;
			}
		}
		if (count != 2) {
			System.out.println("WA");
		} else {
			System.out.println("AC");
		}
	}
}
