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

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

        String S = sc.next();
        int yyyy = Integer.parseInt(S.substring(0, 4));
        int mm = Integer.parseInt(S.substring(5, 7));
        int dd = Integer.parseInt(S.substring(8, 10));
        sc.close();

        boolean heisei = false;
        if (yyyy < 2019) {
            heisei = true;
        } else if (yyyy == 2019) {
            if (mm <= 4) {
                heisei = true;
            }
        }
        if (heisei) {
            out.printf("Heisei\n");
        } else {
            out.printf("TBD\n");
        }
        out.flush();
    }
} import java.util.*; util.* java import java.io.*; io.* java class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        PrintWriter out = new PrintWriter(System.out);

        String S = sc.next();
        int yyyy = Integer.parseInt(S.substring(0, 4));
        int mm = Integer.parseInt(S.substring(5, 7));
        int dd = Integer.parseInt(S.substring(8, 10));
        sc.close();

        boolean heisei = false;
        if (yyyy < 2019) {
            heisei = true;
        } else if (yyyy == 2019) {
            if (mm <= 4) {
                heisei = true;
            }
        }
        if (heisei) {
            out.printf("Heisei\n");
        } else {
            out.printf("TBD\n");
        }
        out.flush();
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        PrintWriter out = new PrintWriter(System.out);

        String S = sc.next();
        int yyyy = Integer.parseInt(S.substring(0, 4));
        int mm = Integer.parseInt(S.substring(5, 7));
        int dd = Integer.parseInt(S.substring(8, 10));
        sc.close();

        boolean heisei = false;
        if (yyyy < 2019) {
            heisei = true;
        } else if (yyyy == 2019) {
            if (mm <= 4) {
                heisei = true;
            }
        }
        if (heisei) {
            out.printf("Heisei\n");
        } else {
            out.printf("TBD\n");
        }
        out.flush();
    } main {
        Scanner sc = new Scanner(System.in);
        PrintWriter out = new PrintWriter(System.out);

        String S = sc.next();
        int yyyy = Integer.parseInt(S.substring(0, 4));
        int mm = Integer.parseInt(S.substring(5, 7));
        int dd = Integer.parseInt(S.substring(8, 10));
        sc.close();

        boolean heisei = false;
        if (yyyy < 2019) {
            heisei = true;
        } else if (yyyy == 2019) {
            if (mm <= 4) {
                heisei = true;
            }
        }
        if (heisei) {
            out.printf("Heisei\n");
        } else {
            out.printf("TBD\n");
        }
        out.flush();
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) PrintWriter out = new PrintWriter(System.out); out new PrintWriter(System.out) String S = sc.next(); S sc.next() sc.next sc int yyyy = Integer.parseInt(S.substring(0, 4)); yyyy Integer.parseInt(S.substring(0, 4)) Integer.parseInt Integer S.substring(0, 4) S.substring S 0 4 int mm = Integer.parseInt(S.substring(5, 7)); mm Integer.parseInt(S.substring(5, 7)) Integer.parseInt Integer S.substring(5, 7) S.substring S 5 7 int dd = Integer.parseInt(S.substring(8, 10)); dd Integer.parseInt(S.substring(8, 10)) Integer.parseInt Integer S.substring(8, 10) S.substring S 8 10 sc.close() sc.close sc boolean heisei = false; heisei false if (yyyy < 2019) {
            heisei = true;
        } else if (yyyy == 2019) {
            if (mm <= 4) {
                heisei = true;
            }
        } yyyy < 2019 yyyy 2019 {
            heisei = true;
        } heisei = true heisei true if (yyyy == 2019) {
            if (mm <= 4) {
                heisei = true;
            }
        } yyyy == 2019 yyyy 2019 {
            if (mm <= 4) {
                heisei = true;
            }
        } if (mm <= 4) {
                heisei = true;
            } mm <= 4 mm 4 {
                heisei = true;
            } heisei = true heisei true if (heisei) {
            out.printf("Heisei\n");
        } else {
            out.printf("TBD\n");
        } heisei {
            out.printf("Heisei\n");
        } out.printf("Heisei\n") out.printf out "Heisei\n" {
            out.printf("TBD\n");
        } out.printf("TBD\n") out.printf out "TBD\n" out.flush() out.flush out String[] args args
import java.util.*;
import java.io.*;

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

        String S = sc.next();
        int yyyy = Integer.parseInt(S.substring(0, 4));
        int mm = Integer.parseInt(S.substring(5, 7));
        int dd = Integer.parseInt(S.substring(8, 10));
        sc.close();

        boolean heisei = false;
        if (yyyy < 2019) {
            heisei = true;
        } else if (yyyy == 2019) {
            if (mm <= 4) {
                heisei = true;
            }
        }
        if (heisei) {
            out.printf("Heisei\n");
        } else {
            out.printf("TBD\n");
        }
        out.flush();
    }
}
