S = input()
y = int(S[:4])
m = int(S[5:7])
d = int(S[8:])
if y < 2019:
    print("Heisei")
elif y == 2019 and m < 4:
    print("Heisei")
elif y == 2019 and m == 4 and d <= 30:
    print("Heisei")
else:
    print("TBD") S = input() S input() input y = int(S[:4]) y int(S[:4]) int S[:4] S :4 4 m = int(S[5:7]) m int(S[5:7]) int S[5:7] S 5:7 5 7 d = int(S[8:]) d int(S[8:]) int S[8:] S 8: 8 if y < 2019:
    print("Heisei")
elif y == 2019 and m < 4:
    print("Heisei")
elif y == 2019 and m == 4 and d <= 30:
    print("Heisei")
else:
    print("TBD") y < 2019 y 2019 print("Heisei") print "Heisei" elif y == 2019 and m < 4:
    print("Heisei") y == 2019 and m < 4 y == 2019 y 2019 m < 4 m 4 print("Heisei") print "Heisei" elif y == 2019 and m == 4 and d <= 30:
    print("Heisei") y == 2019 and m == 4 and d <= 30 y == 2019 and m == 4 y == 2019 y 2019 m == 4 m 4 d <= 30 d 30 print("Heisei") print "Heisei" print("TBD") print "TBD" m = int(S[5:7]) int(S[5:7]) m y = int(S[:4]) int(S[:4]) y d = int(S[8:]) int(S[8:]) d S = input() input() S
S = input()
y = int(S[:4])
m = int(S[5:7])
d = int(S[8:])
if y < 2019:
    print("Heisei")
elif y == 2019 and m < 4:
    print("Heisei")
elif y == 2019 and m == 4 and d <= 30:
    print("Heisei")
else:
    print("TBD")