import java.util.Scanner; public class Tatakai { public static void main(String args[]){ Scanner sc = new Scanner(System.in); int west = 0; int east = 0; String str = sc.next(); for(int i=0; i=3){ System.out.println("West"); return; } } if(str.charAt(i) == 'O'){ east++; west = 0; if(east>=3){ System.out.println("East"); return; } } } System.out.println("NA"); } }