Language: Java






public class Main
{
     public static void main(String[]args)throws IOException
     {
           BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
           String s = br.readLine();
           Map<Character,Integer> map = new HashMap<Character,Integer>();
            map.put('A',0);
            map.put('B',0);
           for(int i=0;i<3;i++)
           {
                char ch = s.charAt(i);
                if(ch=='A')
                {
                      value=map.get('A');
                      value++;
                      map.put('A',value);
                }
                else
                {
                      value=map.get('B');
                       value++;
                      map.put('B',value);
                }
           }
           if(map.get('A')==3 || map.get('B')==3)
           {
                System.out.println("No");
           }
           else
           {
                System.out.println("Yes");
           }
     }
}
             
             
             
             
             
             
             
             
             

Compiler output:
Main.java:8: error: cannot find symbol
     public static void main(String[]args)throws IOException
                                                 ^
  symbol:   class IOException
  location: class Main
Main.java:10: error: cannot find symbol
           BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
           ^
  symbol:   class BufferedReader
  location: class Main
Main.java:10: error: cannot find symbol
           BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
                                   ^
  symbol:   class BufferedReader
  location: class Main
Main.java:10: error: cannot find symbol
           BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
                                                      ^
  symbol:   class InputStreamReader
  location: class Main
Main.java:12: error: cannot find symbol
           Map<Character,Integer> map = new HashMap<Character,Integer>();
           ^
  symbol:   class Map
  location: class Main
Main.java:12: error: cannot find symbol
           Map<Character,Integer> map = new HashMap<Character,Integer>();
                                            ^
  symbol:   class HashMap
  location: class Main
Main.java:20: error: cannot find symbol
                      value=map.get('A');
                      ^
  symbol:   variable value
  location: class Main
Main.java:21: error: cannot find symbol
                      value++;
                      ^
  symbol:   variable value
  location: class Main
Main.java:22: error: cannot find symbol
                      map.put('A',value);
                                  ^
  symbol:   variable value
  location: class Main
Main.java:26: error: cannot find symbol
                      value=map.get('B');
                      ^
  symbol:   variable value
  location: class Main
Main.java:27: error: cannot find symbol
                       value++;
                       ^
  symbol:   variable value
  location: class Main
Main.java:28: error: cannot find symbol
                      map.put('B',value);
                                  ^
  symbol:   variable value
  location: class Main
12 errors