import java.util.*;
import java.io.*;
import java.lang.*;

public class Main {
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        String a = sc.next();

        int m = Integer.parseInt(a.substring(5,7));
        int d = Integer.parseInt(a.substring(8,10));

        if (m<=4 && d <= 30)
            System.out.println("Heisei");
        else
            System.out.println("TBD");
    }
} import java.util.*; util.* java import java.io.*; io.* java import java.lang.*; lang.* java public class Main {
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        String a = sc.next();

        int m = Integer.parseInt(a.substring(5,7));
        int d = Integer.parseInt(a.substring(8,10));

        if (m<=4 && d <= 30)
            System.out.println("Heisei");
        else
            System.out.println("TBD");
    }
} Main public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        String a = sc.next();

        int m = Integer.parseInt(a.substring(5,7));
        int d = Integer.parseInt(a.substring(8,10));

        if (m<=4 && d <= 30)
            System.out.println("Heisei");
        else
            System.out.println("TBD");
    } main {
        Scanner sc = new Scanner(System.in);
        String a = sc.next();

        int m = Integer.parseInt(a.substring(5,7));
        int d = Integer.parseInt(a.substring(8,10));

        if (m<=4 && d <= 30)
            System.out.println("Heisei");
        else
            System.out.println("TBD");
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String a = sc.next(); a sc.next() sc.next sc int m = Integer.parseInt(a.substring(5,7)); m Integer.parseInt(a.substring(5,7)) Integer.parseInt Integer a.substring(5,7) a.substring a 5 7 int d = Integer.parseInt(a.substring(8,10)); d Integer.parseInt(a.substring(8,10)) Integer.parseInt Integer a.substring(8,10) a.substring a 8 10 if (m<=4 && d <= 30)
            System.out.println("Heisei");
        else
            System.out.println("TBD"); m<=4 && d <= 30 m<=4 m 4 d <= 30 d 30 System.out.println("Heisei") System.out.println System.out System System.out "Heisei" System.out.println("TBD") System.out.println System.out System System.out "TBD" String[] args args public class Main {
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        String a = sc.next();

        int m = Integer.parseInt(a.substring(5,7));
        int d = Integer.parseInt(a.substring(8,10));

        if (m<=4 && d <= 30)
            System.out.println("Heisei");
        else
            System.out.println("TBD");
    }
} public class Main {
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        String a = sc.next();

        int m = Integer.parseInt(a.substring(5,7));
        int d = Integer.parseInt(a.substring(8,10));

        if (m<=4 && d <= 30)
            System.out.println("Heisei");
        else
            System.out.println("TBD");
    }
} Main
import java.util.*;
import java.io.*;
import java.lang.*;

public class Main {
    public static void main(String[] args){
        Scanner sc = new Scanner(System.in);
        String a = sc.next();

        int m = Integer.parseInt(a.substring(5,7));
        int d = Integer.parseInt(a.substring(8,10));

        if (m<=4 && d <= 30)
            System.out.println("Heisei");
        else
            System.out.println("TBD");
    }
}
