import java.util.*;
public class Main {
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        String s = sc.next();

        String answer = "Heisei";
        int year, month, day;
        year = Integer.parseInt(s.substring(0,4));
        month =  Integer.parseInt(s.substring(5,7));
        
        if(year > 2019) answer = "TBD";
        if(year == 2019 && month >= 5) answer = "TBD";

        System.out.println(answer);
    }
} import java.util.*; util.* java public class Main {
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        String s = sc.next();

        String answer = "Heisei";
        int year, month, day;
        year = Integer.parseInt(s.substring(0,4));
        month =  Integer.parseInt(s.substring(5,7));
        
        if(year > 2019) answer = "TBD";
        if(year == 2019 && month >= 5) answer = "TBD";

        System.out.println(answer);
    }
} Main public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        String s = sc.next();

        String answer = "Heisei";
        int year, month, day;
        year = Integer.parseInt(s.substring(0,4));
        month =  Integer.parseInt(s.substring(5,7));
        
        if(year > 2019) answer = "TBD";
        if(year == 2019 && month >= 5) answer = "TBD";

        System.out.println(answer);
    } main {
        Scanner sc = new Scanner(System.in);
        String s = sc.next();

        String answer = "Heisei";
        int year, month, day;
        year = Integer.parseInt(s.substring(0,4));
        month =  Integer.parseInt(s.substring(5,7));
        
        if(year > 2019) answer = "TBD";
        if(year == 2019 && month >= 5) answer = "TBD";

        System.out.println(answer);
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String s = sc.next(); s sc.next() sc.next sc String answer = "Heisei"; answer "Heisei" int year year month month day; day year = Integer.parseInt(s.substring(0,4)) year Integer.parseInt(s.substring(0,4)) Integer.parseInt Integer s.substring(0,4) s.substring s 0 4 month =  Integer.parseInt(s.substring(5,7)) month Integer.parseInt(s.substring(5,7)) Integer.parseInt Integer s.substring(5,7) s.substring s 5 7 if(year > 2019) answer = "TBD"; year > 2019 year 2019 answer = "TBD" answer "TBD" if(year == 2019 && month >= 5) answer = "TBD"; year == 2019 && month >= 5 year == 2019 year 2019 month >= 5 month 5 answer = "TBD" answer "TBD" System.out.println(answer) System.out.println System.out System System.out answer String[] args args public class Main {
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        String s = sc.next();

        String answer = "Heisei";
        int year, month, day;
        year = Integer.parseInt(s.substring(0,4));
        month =  Integer.parseInt(s.substring(5,7));
        
        if(year > 2019) answer = "TBD";
        if(year == 2019 && month >= 5) answer = "TBD";

        System.out.println(answer);
    }
} public class Main {
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        String s = sc.next();

        String answer = "Heisei";
        int year, month, day;
        year = Integer.parseInt(s.substring(0,4));
        month =  Integer.parseInt(s.substring(5,7));
        
        if(year > 2019) answer = "TBD";
        if(year == 2019 && month >= 5) answer = "TBD";

        System.out.println(answer);
    }
} Main
import java.util.*;
public class Main {
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        String s = sc.next();

        String answer = "Heisei";
        int year, month, day;
        year = Integer.parseInt(s.substring(0,4));
        month =  Integer.parseInt(s.substring(5,7));
        
        if(year > 2019) answer = "TBD";
        if(year == 2019 && month >= 5) answer = "TBD";

        System.out.println(answer);
    }
}