import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.*;

public class Main {
    public static void main(String[] args) throws Exception {
        
        Scanner sc = new Scanner(System.in);
        String S = sc.next();
        
        SimpleDateFormat sdFormat = new SimpleDateFormat("yyyy/MM/dd");
        Date date1 = sdFormat.parse(S);
        Date date2 = sdFormat.parse("2019/04/30");
        
        String ans = "Heisei";
        if( date2.compareTo(date1) == -1 ) ans = "TBD";
        System.out.println(ans);
        
    }
} import java.text.ParseException; ParseException java.text import java.text.SimpleDateFormat; SimpleDateFormat java.text import java.util.*; util.* java public class Main {
    public static void main(String[] args) throws Exception {
        
        Scanner sc = new Scanner(System.in);
        String S = sc.next();
        
        SimpleDateFormat sdFormat = new SimpleDateFormat("yyyy/MM/dd");
        Date date1 = sdFormat.parse(S);
        Date date2 = sdFormat.parse("2019/04/30");
        
        String ans = "Heisei";
        if( date2.compareTo(date1) == -1 ) ans = "TBD";
        System.out.println(ans);
        
    }
} Main public static void main(String[] args) throws Exception {
        
        Scanner sc = new Scanner(System.in);
        String S = sc.next();
        
        SimpleDateFormat sdFormat = new SimpleDateFormat("yyyy/MM/dd");
        Date date1 = sdFormat.parse(S);
        Date date2 = sdFormat.parse("2019/04/30");
        
        String ans = "Heisei";
        if( date2.compareTo(date1) == -1 ) ans = "TBD";
        System.out.println(ans);
        
    } main {
        
        Scanner sc = new Scanner(System.in);
        String S = sc.next();
        
        SimpleDateFormat sdFormat = new SimpleDateFormat("yyyy/MM/dd");
        Date date1 = sdFormat.parse(S);
        Date date2 = sdFormat.parse("2019/04/30");
        
        String ans = "Heisei";
        if( date2.compareTo(date1) == -1 ) ans = "TBD";
        System.out.println(ans);
        
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String S = sc.next(); S sc.next() sc.next sc SimpleDateFormat sdFormat = new SimpleDateFormat("yyyy/MM/dd"); sdFormat new SimpleDateFormat("yyyy/MM/dd") Date date1 = sdFormat.parse(S); date1 sdFormat.parse(S) sdFormat.parse sdFormat S Date date2 = sdFormat.parse("2019/04/30"); date2 sdFormat.parse("2019/04/30") sdFormat.parse sdFormat "2019/04/30" String ans = "Heisei"; ans "Heisei" if( date2.compareTo(date1) == -1 ) ans = "TBD"; date2.compareTo(date1) == -1 date2.compareTo(date1) date2.compareTo date2 date1 -1 1 ans = "TBD" ans "TBD" System.out.println(ans) System.out.println System.out System System.out ans String[] args args public class Main {
    public static void main(String[] args) throws Exception {
        
        Scanner sc = new Scanner(System.in);
        String S = sc.next();
        
        SimpleDateFormat sdFormat = new SimpleDateFormat("yyyy/MM/dd");
        Date date1 = sdFormat.parse(S);
        Date date2 = sdFormat.parse("2019/04/30");
        
        String ans = "Heisei";
        if( date2.compareTo(date1) == -1 ) ans = "TBD";
        System.out.println(ans);
        
    }
} public class Main {
    public static void main(String[] args) throws Exception {
        
        Scanner sc = new Scanner(System.in);
        String S = sc.next();
        
        SimpleDateFormat sdFormat = new SimpleDateFormat("yyyy/MM/dd");
        Date date1 = sdFormat.parse(S);
        Date date2 = sdFormat.parse("2019/04/30");
        
        String ans = "Heisei";
        if( date2.compareTo(date1) == -1 ) ans = "TBD";
        System.out.println(ans);
        
    }
} Main
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.*;

public class Main {
    public static void main(String[] args) throws Exception {
        
        Scanner sc = new Scanner(System.in);
        String S = sc.next();
        
        SimpleDateFormat sdFormat = new SimpleDateFormat("yyyy/MM/dd");
        Date date1 = sdFormat.parse(S);
        Date date2 = sdFormat.parse("2019/04/30");
        
        String ans = "Heisei";
        if( date2.compareTo(date1) == -1 ) ans = "TBD";
        System.out.println(ans);
        
    }
}
