import java.util.Scanner;

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

	String s = scan.next();

	String yy = s.substring(0,4);
	String mm = s.substring(5,7);
	String dd = s.substring(8,10);

	int year = Integer.parseInt(yy);
	if(year < 2019){
	    System.out.println("Heisei");
	}else if(year == 2019){
	    if(mm.equals("01") || mm.equals("02") ||
	       mm.equals("03") || mm.equals("04")){
		System.out.println("Heisei");
	    }else{
		System.out.println("TBD");
	    }
	}else{
	    System.out.println("TBD");
	}

    }
} import java.util.Scanner; Scanner java.util public class Main{
    public static void main(String[] args){
	Scanner scan = new Scanner(System.in);

	String s = scan.next();

	String yy = s.substring(0,4);
	String mm = s.substring(5,7);
	String dd = s.substring(8,10);

	int year = Integer.parseInt(yy);
	if(year < 2019){
	    System.out.println("Heisei");
	}else if(year == 2019){
	    if(mm.equals("01") || mm.equals("02") ||
	       mm.equals("03") || mm.equals("04")){
		System.out.println("Heisei");
	    }else{
		System.out.println("TBD");
	    }
	}else{
	    System.out.println("TBD");
	}

    }
} Main public static void main(String[] args){
	Scanner scan = new Scanner(System.in);

	String s = scan.next();

	String yy = s.substring(0,4);
	String mm = s.substring(5,7);
	String dd = s.substring(8,10);

	int year = Integer.parseInt(yy);
	if(year < 2019){
	    System.out.println("Heisei");
	}else if(year == 2019){
	    if(mm.equals("01") || mm.equals("02") ||
	       mm.equals("03") || mm.equals("04")){
		System.out.println("Heisei");
	    }else{
		System.out.println("TBD");
	    }
	}else{
	    System.out.println("TBD");
	}

    } main {
	Scanner scan = new Scanner(System.in);

	String s = scan.next();

	String yy = s.substring(0,4);
	String mm = s.substring(5,7);
	String dd = s.substring(8,10);

	int year = Integer.parseInt(yy);
	if(year < 2019){
	    System.out.println("Heisei");
	}else if(year == 2019){
	    if(mm.equals("01") || mm.equals("02") ||
	       mm.equals("03") || mm.equals("04")){
		System.out.println("Heisei");
	    }else{
		System.out.println("TBD");
	    }
	}else{
	    System.out.println("TBD");
	}

    } Scanner scan = new Scanner(System.in); scan new Scanner(System.in) String s = scan.next(); s scan.next() scan.next scan String yy = s.substring(0,4); yy s.substring(0,4) s.substring s 0 4 String mm = s.substring(5,7); mm s.substring(5,7) s.substring s 5 7 String dd = s.substring(8,10); dd s.substring(8,10) s.substring s 8 10 int year = Integer.parseInt(yy); year Integer.parseInt(yy) Integer.parseInt Integer yy if(year < 2019){
	    System.out.println("Heisei");
	}else if(year == 2019){
	    if(mm.equals("01") || mm.equals("02") ||
	       mm.equals("03") || mm.equals("04")){
		System.out.println("Heisei");
	    }else{
		System.out.println("TBD");
	    }
	}else{
	    System.out.println("TBD");
	} year < 2019 year 2019 {
	    System.out.println("Heisei");
	} System.out.println("Heisei") System.out.println System.out System System.out "Heisei" if(year == 2019){
	    if(mm.equals("01") || mm.equals("02") ||
	       mm.equals("03") || mm.equals("04")){
		System.out.println("Heisei");
	    }else{
		System.out.println("TBD");
	    }
	}else{
	    System.out.println("TBD");
	} year == 2019 year 2019 {
	    if(mm.equals("01") || mm.equals("02") ||
	       mm.equals("03") || mm.equals("04")){
		System.out.println("Heisei");
	    }else{
		System.out.println("TBD");
	    }
	} if(mm.equals("01") || mm.equals("02") ||
	       mm.equals("03") || mm.equals("04")){
		System.out.println("Heisei");
	    }else{
		System.out.println("TBD");
	    } mm.equals("01") || mm.equals("02") ||
	       mm.equals("03") || mm.equals("04") mm.equals("03") mm.equals("01") || mm.equals("02") ||
	       mm.equals("03") || mm.equals("04") mm.equals("01") mm.equals mm "01" mm.equals("02") mm.equals mm "02" mm.equals("03") mm.equals mm "03" mm.equals("04") mm.equals mm "04" {
		System.out.println("Heisei");
	    } System.out.println("Heisei") System.out.println System.out System System.out "Heisei" {
		System.out.println("TBD");
	    } System.out.println("TBD") System.out.println System.out System System.out "TBD" {
	    System.out.println("TBD");
	} 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 scan = new Scanner(System.in);

	String s = scan.next();

	String yy = s.substring(0,4);
	String mm = s.substring(5,7);
	String dd = s.substring(8,10);

	int year = Integer.parseInt(yy);
	if(year < 2019){
	    System.out.println("Heisei");
	}else if(year == 2019){
	    if(mm.equals("01") || mm.equals("02") ||
	       mm.equals("03") || mm.equals("04")){
		System.out.println("Heisei");
	    }else{
		System.out.println("TBD");
	    }
	}else{
	    System.out.println("TBD");
	}

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

	String s = scan.next();

	String yy = s.substring(0,4);
	String mm = s.substring(5,7);
	String dd = s.substring(8,10);

	int year = Integer.parseInt(yy);
	if(year < 2019){
	    System.out.println("Heisei");
	}else if(year == 2019){
	    if(mm.equals("01") || mm.equals("02") ||
	       mm.equals("03") || mm.equals("04")){
		System.out.println("Heisei");
	    }else{
		System.out.println("TBD");
	    }
	}else{
	    System.out.println("TBD");
	}

    }
} Main
import java.util.Scanner;

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

	String s = scan.next();

	String yy = s.substring(0,4);
	String mm = s.substring(5,7);
	String dd = s.substring(8,10);

	int year = Integer.parseInt(yy);
	if(year < 2019){
	    System.out.println("Heisei");
	}else if(year == 2019){
	    if(mm.equals("01") || mm.equals("02") ||
	       mm.equals("03") || mm.equals("04")){
		System.out.println("Heisei");
	    }else{
		System.out.println("TBD");
	    }
	}else{
	    System.out.println("TBD");
	}

    }
}
