import java.util.*;

public class Main{
  
  public static void main (String[] args){
    
    Main main = new Main();
    main.solve();
  }
  
  private void solve(){
    
    Scanner scanner = new Scanner (System.in);
    
    String dates = scanner.nextLine();
    
    char month1 = dates.charAt(5);
    char month2 = dates.charAt(6);
    
    if (month1=='0'){
    	if (month2=='1'||month2=='2'||month2=='3'||month2=='4'){
			System.out.println("Heisei");
    	} else {
      		System.out.println("TBD");
    	}
    } else {
      System.out.println("TBD");
    }
  }
} import java.util.*; util.* java public class Main{
  
  public static void main (String[] args){
    
    Main main = new Main();
    main.solve();
  }
  
  private void solve(){
    
    Scanner scanner = new Scanner (System.in);
    
    String dates = scanner.nextLine();
    
    char month1 = dates.charAt(5);
    char month2 = dates.charAt(6);
    
    if (month1=='0'){
    	if (month2=='1'||month2=='2'||month2=='3'||month2=='4'){
			System.out.println("Heisei");
    	} else {
      		System.out.println("TBD");
    	}
    } else {
      System.out.println("TBD");
    }
  }
} Main public static void main (String[] args){
    
    Main main = new Main();
    main.solve();
  } main {
    
    Main main = new Main();
    main.solve();
  } Main main = new Main(); main new Main() main.solve() main.solve main String[] args args private void solve(){
    
    Scanner scanner = new Scanner (System.in);
    
    String dates = scanner.nextLine();
    
    char month1 = dates.charAt(5);
    char month2 = dates.charAt(6);
    
    if (month1=='0'){
    	if (month2=='1'||month2=='2'||month2=='3'||month2=='4'){
			System.out.println("Heisei");
    	} else {
      		System.out.println("TBD");
    	}
    } else {
      System.out.println("TBD");
    }
  } solve {
    
    Scanner scanner = new Scanner (System.in);
    
    String dates = scanner.nextLine();
    
    char month1 = dates.charAt(5);
    char month2 = dates.charAt(6);
    
    if (month1=='0'){
    	if (month2=='1'||month2=='2'||month2=='3'||month2=='4'){
			System.out.println("Heisei");
    	} else {
      		System.out.println("TBD");
    	}
    } else {
      System.out.println("TBD");
    }
  } Scanner scanner = new Scanner (System.in); scanner new Scanner (System.in) String dates = scanner.nextLine(); dates scanner.nextLine() scanner.nextLine scanner char month1 = dates.charAt(5); month1 dates.charAt(5) dates.charAt dates 5 char month2 = dates.charAt(6); month2 dates.charAt(6) dates.charAt dates 6 if (month1=='0'){
    	if (month2=='1'||month2=='2'||month2=='3'||month2=='4'){
			System.out.println("Heisei");
    	} else {
      		System.out.println("TBD");
    	}
    } else {
      System.out.println("TBD");
    } month1=='0' month1 '0' {
    	if (month2=='1'||month2=='2'||month2=='3'||month2=='4'){
			System.out.println("Heisei");
    	} else {
      		System.out.println("TBD");
    	}
    } if (month2=='1'||month2=='2'||month2=='3'||month2=='4'){
			System.out.println("Heisei");
    	} else {
      		System.out.println("TBD");
    	} month2=='1'||month2=='2'||month2=='3'||month2=='4' month2=='3' month2=='1'||month2=='2'||month2=='3'||month2=='4' month2=='1' month2 '1' month2=='2' month2 '2' month2=='3' month2 '3' month2=='4' month2 '4' {
			System.out.println("Heisei");
    	} System.out.println("Heisei") System.out.println System.out System System.out "Heisei" {
      		System.out.println("TBD");
    	} System.out.println("TBD") System.out.println System.out System System.out "TBD" {
      System.out.println("TBD");
    } System.out.println("TBD") System.out.println System.out System System.out "TBD" public class Main{
  
  public static void main (String[] args){
    
    Main main = new Main();
    main.solve();
  }
  
  private void solve(){
    
    Scanner scanner = new Scanner (System.in);
    
    String dates = scanner.nextLine();
    
    char month1 = dates.charAt(5);
    char month2 = dates.charAt(6);
    
    if (month1=='0'){
    	if (month2=='1'||month2=='2'||month2=='3'||month2=='4'){
			System.out.println("Heisei");
    	} else {
      		System.out.println("TBD");
    	}
    } else {
      System.out.println("TBD");
    }
  }
} public class Main{
  
  public static void main (String[] args){
    
    Main main = new Main();
    main.solve();
  }
  
  private void solve(){
    
    Scanner scanner = new Scanner (System.in);
    
    String dates = scanner.nextLine();
    
    char month1 = dates.charAt(5);
    char month2 = dates.charAt(6);
    
    if (month1=='0'){
    	if (month2=='1'||month2=='2'||month2=='3'||month2=='4'){
			System.out.println("Heisei");
    	} else {
      		System.out.println("TBD");
    	}
    } else {
      System.out.println("TBD");
    }
  }
} Main
import java.util.*;

public class Main{
  
  public static void main (String[] args){
    
    Main main = new Main();
    main.solve();
  }
  
  private void solve(){
    
    Scanner scanner = new Scanner (System.in);
    
    String dates = scanner.nextLine();
    
    char month1 = dates.charAt(5);
    char month2 = dates.charAt(6);
    
    if (month1=='0'){
    	if (month2=='1'||month2=='2'||month2=='3'||month2=='4'){
			System.out.println("Heisei");
    	} else {
      		System.out.println("TBD");
    	}
    } else {
      System.out.println("TBD");
    }
  }
}