import java.util.Scanner;

class Main{


	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);			//文字の入力

		String n = sc.next();
		int y = Integer.parseInt(n.substring(0,4));
		int m = Integer.parseInt(n.substring(5,7));
		int d = Integer.parseInt(n.substring(8));
	//	System.out.println(y + " " + m + " " + d);
		if(y >= 2019 && m > 4){
			System.out.println("TBD");
		}else{
			System.out.println("Heisei");

		}
	}
}
 import java.util.Scanner; Scanner java.util class Main{


	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);			//文字の入力

		String n = sc.next();
		int y = Integer.parseInt(n.substring(0,4));
		int m = Integer.parseInt(n.substring(5,7));
		int d = Integer.parseInt(n.substring(8));
	//	System.out.println(y + " " + m + " " + d);
		if(y >= 2019 && m > 4){
			System.out.println("TBD");
		}else{
			System.out.println("Heisei");

		}
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);			//文字の入力

		String n = sc.next();
		int y = Integer.parseInt(n.substring(0,4));
		int m = Integer.parseInt(n.substring(5,7));
		int d = Integer.parseInt(n.substring(8));
	//	System.out.println(y + " " + m + " " + d);
		if(y >= 2019 && m > 4){
			System.out.println("TBD");
		}else{
			System.out.println("Heisei");

		}
	} main {
		Scanner sc = new Scanner(System.in);			//文字の入力

		String n = sc.next();
		int y = Integer.parseInt(n.substring(0,4));
		int m = Integer.parseInt(n.substring(5,7));
		int d = Integer.parseInt(n.substring(8));
	//	System.out.println(y + " " + m + " " + d);
		if(y >= 2019 && m > 4){
			System.out.println("TBD");
		}else{
			System.out.println("Heisei");

		}
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String n = sc.next(); n sc.next() sc.next sc int y = Integer.parseInt(n.substring(0,4)); y Integer.parseInt(n.substring(0,4)) Integer.parseInt Integer n.substring(0,4) n.substring n 0 4 int m = Integer.parseInt(n.substring(5,7)); m Integer.parseInt(n.substring(5,7)) Integer.parseInt Integer n.substring(5,7) n.substring n 5 7 int d = Integer.parseInt(n.substring(8)); d Integer.parseInt(n.substring(8)) Integer.parseInt Integer n.substring(8) n.substring n 8 if(y >= 2019 && m > 4){
			System.out.println("TBD");
		}else{
			System.out.println("Heisei");

		} y >= 2019 && m > 4 y >= 2019 y 2019 m > 4 m 4 {
			System.out.println("TBD");
		} System.out.println("TBD") System.out.println System.out System System.out "TBD" {
			System.out.println("Heisei");

		} System.out.println("Heisei") System.out.println System.out System System.out "Heisei" String[] args args
import java.util.Scanner;

class Main{


	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);			//文字の入力

		String n = sc.next();
		int y = Integer.parseInt(n.substring(0,4));
		int m = Integer.parseInt(n.substring(5,7));
		int d = Integer.parseInt(n.substring(8));
	//	System.out.println(y + " " + m + " " + d);
		if(y >= 2019 && m > 4){
			System.out.println("TBD");
		}else{
			System.out.println("Heisei");

		}
	}
}

