import java.util.*;
import java.time.*;
import java.time.format.*;
public class Main{
	public static void main(String[] args){
    	Scanner sc = new Scanner(System.in);
      String str = sc.next();
      DateTimeFormatter f = 
        DateTimeFormatter.ofPattern("yyyy/MM/dd");
      LocalDate d =
        LocalDate.parse(str,f);
      LocalDate reiwa =
        LocalDate.parse("2019/04/30",f);
      if(d.isAfter(reiwa))
        System.out.println("TBD");
      else System.out.println("Heisei");
    }
} import java.util.*; util.* java import java.time.*; time.* java import java.time.format.*; format.* java.time public class Main{
	public static void main(String[] args){
    	Scanner sc = new Scanner(System.in);
      String str = sc.next();
      DateTimeFormatter f = 
        DateTimeFormatter.ofPattern("yyyy/MM/dd");
      LocalDate d =
        LocalDate.parse(str,f);
      LocalDate reiwa =
        LocalDate.parse("2019/04/30",f);
      if(d.isAfter(reiwa))
        System.out.println("TBD");
      else System.out.println("Heisei");
    }
} Main public static void main(String[] args){
    	Scanner sc = new Scanner(System.in);
      String str = sc.next();
      DateTimeFormatter f = 
        DateTimeFormatter.ofPattern("yyyy/MM/dd");
      LocalDate d =
        LocalDate.parse(str,f);
      LocalDate reiwa =
        LocalDate.parse("2019/04/30",f);
      if(d.isAfter(reiwa))
        System.out.println("TBD");
      else System.out.println("Heisei");
    } main {
    	Scanner sc = new Scanner(System.in);
      String str = sc.next();
      DateTimeFormatter f = 
        DateTimeFormatter.ofPattern("yyyy/MM/dd");
      LocalDate d =
        LocalDate.parse(str,f);
      LocalDate reiwa =
        LocalDate.parse("2019/04/30",f);
      if(d.isAfter(reiwa))
        System.out.println("TBD");
      else System.out.println("Heisei");
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String str = sc.next(); str sc.next() sc.next sc DateTimeFormatter f = 
        DateTimeFormatter.ofPattern("yyyy/MM/dd"); f DateTimeFormatter.ofPattern("yyyy/MM/dd") DateTimeFormatter.ofPattern DateTimeFormatter "yyyy/MM/dd" LocalDate d =
        LocalDate.parse(str,f); d LocalDate.parse(str,f) LocalDate.parse LocalDate str f LocalDate reiwa =
        LocalDate.parse("2019/04/30",f); reiwa LocalDate.parse("2019/04/30",f) LocalDate.parse LocalDate "2019/04/30" f if(d.isAfter(reiwa))
        System.out.println("TBD");
      else System.out.println("Heisei"); d.isAfter(reiwa) d.isAfter d reiwa System.out.println("TBD") System.out.println System.out System System.out "TBD" System.out.println("Heisei") System.out.println System.out System System.out "Heisei" String[] args args public class Main{
	public static void main(String[] args){
    	Scanner sc = new Scanner(System.in);
      String str = sc.next();
      DateTimeFormatter f = 
        DateTimeFormatter.ofPattern("yyyy/MM/dd");
      LocalDate d =
        LocalDate.parse(str,f);
      LocalDate reiwa =
        LocalDate.parse("2019/04/30",f);
      if(d.isAfter(reiwa))
        System.out.println("TBD");
      else System.out.println("Heisei");
    }
} public class Main{
	public static void main(String[] args){
    	Scanner sc = new Scanner(System.in);
      String str = sc.next();
      DateTimeFormatter f = 
        DateTimeFormatter.ofPattern("yyyy/MM/dd");
      LocalDate d =
        LocalDate.parse(str,f);
      LocalDate reiwa =
        LocalDate.parse("2019/04/30",f);
      if(d.isAfter(reiwa))
        System.out.println("TBD");
      else System.out.println("Heisei");
    }
} Main
import java.util.*;
import java.time.*;
import java.time.format.*;
public class Main{
	public static void main(String[] args){
    	Scanner sc = new Scanner(System.in);
      String str = sc.next();
      DateTimeFormatter f = 
        DateTimeFormatter.ofPattern("yyyy/MM/dd");
      LocalDate d =
        LocalDate.parse(str,f);
      LocalDate reiwa =
        LocalDate.parse("2019/04/30",f);
      if(d.isAfter(reiwa))
        System.out.println("TBD");
      else System.out.println("Heisei");
    }
}
