import java.util.*;
import java.lang.*;
public class Main{
public static void main(String [] args){
Scanner in = new Scanner(System.in);
  String s = in.next();
  
  for(int i =0;i<s.length()-2;i++){
  if(s.charAt(i)==s.charAt(i+1) && s.charAt(i+1)==s.charAt(i+2)){
  System.out.print("No");
  }
    else{
      System.out.print("Yes");
    }
  }
}
} import java.util.*; util.* java import java.lang.*; lang.* java public class Main{
public static void main(String [] args){
Scanner in = new Scanner(System.in);
  String s = in.next();
  
  for(int i =0;i<s.length()-2;i++){
  if(s.charAt(i)==s.charAt(i+1) && s.charAt(i+1)==s.charAt(i+2)){
  System.out.print("No");
  }
    else{
      System.out.print("Yes");
    }
  }
}
} Main public static void main(String [] args){
Scanner in = new Scanner(System.in);
  String s = in.next();
  
  for(int i =0;i<s.length()-2;i++){
  if(s.charAt(i)==s.charAt(i+1) && s.charAt(i+1)==s.charAt(i+2)){
  System.out.print("No");
  }
    else{
      System.out.print("Yes");
    }
  }
} main {
Scanner in = new Scanner(System.in);
  String s = in.next();
  
  for(int i =0;i<s.length()-2;i++){
  if(s.charAt(i)==s.charAt(i+1) && s.charAt(i+1)==s.charAt(i+2)){
  System.out.print("No");
  }
    else{
      System.out.print("Yes");
    }
  }
} Scanner in = new Scanner(System.in); in new Scanner(System.in) String s = in.next(); s in.next() in.next in for(int i =0;i<s.length()-2;i++){
  if(s.charAt(i)==s.charAt(i+1) && s.charAt(i+1)==s.charAt(i+2)){
  System.out.print("No");
  }
    else{
      System.out.print("Yes");
    }
  } int i =0; int i =0; i 0 i<s.length()-2 i s.length()-2 s.length() s.length s 2 i++ i++ i {
  if(s.charAt(i)==s.charAt(i+1) && s.charAt(i+1)==s.charAt(i+2)){
  System.out.print("No");
  }
    else{
      System.out.print("Yes");
    }
  } {
  if(s.charAt(i)==s.charAt(i+1) && s.charAt(i+1)==s.charAt(i+2)){
  System.out.print("No");
  }
    else{
      System.out.print("Yes");
    }
  } if(s.charAt(i)==s.charAt(i+1) && s.charAt(i+1)==s.charAt(i+2)){
  System.out.print("No");
  }
    else{
      System.out.print("Yes");
    } s.charAt(i)==s.charAt(i+1) && s.charAt(i+1)==s.charAt(i+2) s.charAt(i)==s.charAt(i+1) s.charAt(i) s.charAt s i s.charAt(i+1) s.charAt s i+1 i 1 s.charAt(i+1)==s.charAt(i+2) s.charAt(i+1) s.charAt s i+1 i 1 s.charAt(i+2) s.charAt s i+2 i 2 {
  System.out.print("No");
  } System.out.print("No") System.out.print System.out System System.out "No" {
      System.out.print("Yes");
    } System.out.print("Yes") System.out.print System.out System System.out "Yes" String [] args args public class Main{
public static void main(String [] args){
Scanner in = new Scanner(System.in);
  String s = in.next();
  
  for(int i =0;i<s.length()-2;i++){
  if(s.charAt(i)==s.charAt(i+1) && s.charAt(i+1)==s.charAt(i+2)){
  System.out.print("No");
  }
    else{
      System.out.print("Yes");
    }
  }
}
} public class Main{
public static void main(String [] args){
Scanner in = new Scanner(System.in);
  String s = in.next();
  
  for(int i =0;i<s.length()-2;i++){
  if(s.charAt(i)==s.charAt(i+1) && s.charAt(i+1)==s.charAt(i+2)){
  System.out.print("No");
  }
    else{
      System.out.print("Yes");
    }
  }
}
} Main
import java.util.*;
import java.lang.*;
public class Main{
public static void main(String [] args){
Scanner in = new Scanner(System.in);
  String s = in.next();
  
  for(int i =0;i<s.length()-2;i++){
  if(s.charAt(i)==s.charAt(i+1) && s.charAt(i+1)==s.charAt(i+2)){
  System.out.print("No");
  }
    else{
      System.out.print("Yes");
    }
  }
}
}