import java.util.Scanner;
import java.util.regex.Matcher;
import java.util.regex.Pattern;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String str = sc.next();
		sc.close();
		
		Pattern pattern = Pattern.compile("^A[a-z]+C[a-z]+$");
		Matcher matcer = pattern.matcher(str);
		if(matcer.find()) {
			System.out.println("AC");
		} else {
			System.out.println("WA");
		}
		
	}

} import java.util.Scanner; Scanner java.util import java.util.regex.Matcher; Matcher java.util.regex import java.util.regex.Pattern; Pattern java.util.regex public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String str = sc.next();
		sc.close();
		
		Pattern pattern = Pattern.compile("^A[a-z]+C[a-z]+$");
		Matcher matcer = pattern.matcher(str);
		if(matcer.find()) {
			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();
		sc.close();
		
		Pattern pattern = Pattern.compile("^A[a-z]+C[a-z]+$");
		Matcher matcer = pattern.matcher(str);
		if(matcer.find()) {
			System.out.println("AC");
		} else {
			System.out.println("WA");
		}
		
	} main {
		Scanner sc = new Scanner(System.in);
		String str = sc.next();
		sc.close();
		
		Pattern pattern = Pattern.compile("^A[a-z]+C[a-z]+$");
		Matcher matcer = pattern.matcher(str);
		if(matcer.find()) {
			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 sc.close() sc.close sc Pattern pattern = Pattern.compile("^A[a-z]+C[a-z]+$"); pattern Pattern.compile("^A[a-z]+C[a-z]+$") Pattern.compile Pattern "^A[a-z]+C[a-z]+$" Matcher matcer = pattern.matcher(str); matcer pattern.matcher(str) pattern.matcher pattern str if(matcer.find()) {
			System.out.println("AC");
		} else {
			System.out.println("WA");
		} matcer.find() matcer.find matcer {
			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();
		sc.close();
		
		Pattern pattern = Pattern.compile("^A[a-z]+C[a-z]+$");
		Matcher matcer = pattern.matcher(str);
		if(matcer.find()) {
			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();
		sc.close();
		
		Pattern pattern = Pattern.compile("^A[a-z]+C[a-z]+$");
		Matcher matcer = pattern.matcher(str);
		if(matcer.find()) {
			System.out.println("AC");
		} else {
			System.out.println("WA");
		}
		
	}

} Main
import java.util.Scanner;
import java.util.regex.Matcher;
import java.util.regex.Pattern;

public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		String str = sc.next();
		sc.close();
		
		Pattern pattern = Pattern.compile("^A[a-z]+C[a-z]+$");
		Matcher matcer = pattern.matcher(str);
		if(matcer.find()) {
			System.out.println("AC");
		} else {
			System.out.println("WA");
		}
		
	}

}