import datetime



a = eval(input())

b = datetime.datetime.strptime(a, '%Y/%m/%d')

c = datetime.datetime(2019, 4, 30)



if b <= c:

	print('Heisei')

else:

	print('TBD')
a = eval(input())



if a[5:7] <= '04':

	print('Heisei')

else:

	print('TBD')
import datetime

a = eval(input())
b = datetime.datetime.strptime(a, "%Y/%m/%d")
c = datetime.datetime(2019, 4, 30)
if b <= c:
    print("Heisei")
else:
    print("TBD")

a = eval(input())
if a[5:7] <= "04":
    print("Heisei")
else:
    print("TBD")

-import datetime - -b = datetime.datetime.strptime(a, "%Y/%m/%d") -c = datetime.datetime(2019, 4, 30) -if b <= c: +if a[5:7] <= "04":