Language: Java

import java.util.*;

public class Main{
    public static void main(String[]args){
        Scanner sc=new Scanner(System.in);
        String s=sc.next();
int w,e,n,s;
        for(int i=0;i<s.length();i++){
              if(s.charAt(i)==`W`)  w++;
if(s.charAt(i)==`E`)  e++;
if(s.charAt(i)==`S`)  s++;
if(s.charAt(i)==`N`)  n++;
}
if(w==0  && e!=0) System.out.println( “No”);
else if(e==0  && w!=0) System.out.println( “No”); 

else if(s==0  && n!=0) System.out.println( “No”); 

else if(n==0  && s!=0) System.out.println( “No”); 

else System.out.println(“Yes”);
    }
}


Compiler output:
Main.java:9: error: illegal character: '`'
              if(s.charAt(i)==`W`)  w++;
                              ^
Main.java:9: error: illegal character: '`'
              if(s.charAt(i)==`W`)  w++;
                                ^
Main.java:9: error: not a statement
              if(s.charAt(i)==`W`)  w++;
                               ^
Main.java:10: error: illegal character: '`'
if(s.charAt(i)==`E`)  e++;
                ^
Main.java:10: error: illegal character: '`'
if(s.charAt(i)==`E`)  e++;
                  ^
Main.java:10: error: not a statement
if(s.charAt(i)==`E`)  e++;
                 ^
Main.java:11: error: illegal character: '`'
if(s.charAt(i)==`S`)  s++;
                ^
Main.java:11: error: illegal character: '`'
if(s.charAt(i)==`S`)  s++;
                  ^
Main.java:11: error: not a statement
if(s.charAt(i)==`S`)  s++;
                 ^
Main.java:12: error: illegal character: '`'
if(s.charAt(i)==`N`)  n++;
                ^
Main.java:12: error: illegal character: '`'
if(s.charAt(i)==`N`)  n++;
                  ^
Main.java:12: error: not a statement
if(s.charAt(i)==`N`)  n++;
                 ^
Main.java:14: error: illegal character: '\u201c'
if(w==0  && e!=0) System.out.println( ?No?);
                                      ^
Main.java:14: error: illegal character: '\u201d'
if(w==0  && e!=0) System.out.println( ?No?);
                                         ^
Main.java:14: error: not a statement
if(w==0  && e!=0) System.out.println( ?No?);
                                       ^
Main.java:15: error: illegal character: '\u201c'
else if(e==0  && w!=0) System.out.println( ?No?); 
                                           ^
Main.java:15: error: 'else' without 'if'
else if(e==0  && w!=0) System.out.println( ?No?); 
^
Main.java:15: error: illegal character: '\u201d'
else if(e==0  && w!=0) System.out.println( ?No?); 
                                              ^
Main.java:15: error: not a statement
else if(e==0  && w!=0) System.out.println( ?No?); 
                                            ^
Main.java:17: error: illegal character: '\u201c'
else if(s==0  && n!=0) System.out.println( ?No?); 
                                           ^
Main.java:17: error: 'else' without 'if'
else if(s==0  && n!=0) System.out.println( ?No?); 
^
Main.java:17: error: illegal character: '\u201d'
else if(s==0  && n!=0) System.out.println( ?No?); 
                                              ^
Main.java:17: error: not a statement
else if(s==0  && n!=0) System.out.println( ?No?); 
                                            ^
Main.java:19: error: illegal character: '\u201c'
else if(n==0  && s!=0) System.out.println( ?No?); 
                                           ^
Main.java:19: error: 'else' without 'if'
else if(n==0  && s!=0) System.out.println( ?No?); 
^
Main.java:19: error: illegal character: '\u201d'
else if(n==0  && s!=0) System.out.println( ?No?); 
                                              ^
Main.java:19: error: not a statement
else if(n==0  && s!=0) System.out.println( ?No?); 
                                            ^
Main.java:21: error: illegal character: '\u201c'
else System.out.println(?Yes?);
                        ^
Main.java:21: error: 'else' without 'if'
else System.out.println(?Yes?);
^
Main.java:21: error: illegal character: '\u201d'
else System.out.println(?Yes?);
                            ^
Main.java:21: error: not a statement
else System.out.println(?Yes?);
                         ^
31 errors