import datetime
S=input()
dte = datetime.datetime.strptime(S, '%Y/%m/%d')
deh = datetime.datetime.strptime("2019/04/30",'%Y/%m/%d')
if dte<=deh:
  print("Heisei")
else:
  print("TBD") import datetime datetime S=input() S input() input dte = datetime.datetime.strptime(S, '%Y/%m/%d') dte datetime.datetime.strptime(S, '%Y/%m/%d') datetime.datetime.strptime datetime.datetime datetime datetime strptime S '%Y/%m/%d' deh = datetime.datetime.strptime("2019/04/30",'%Y/%m/%d') deh datetime.datetime.strptime("2019/04/30",'%Y/%m/%d') datetime.datetime.strptime datetime.datetime datetime datetime strptime "2019/04/30" '%Y/%m/%d' if dte<=deh:
  print("Heisei")
else:
  print("TBD") dte<=deh dte deh print("Heisei") print "Heisei" print("TBD") print "TBD" S=input() input() S deh = datetime.datetime.strptime("2019/04/30",'%Y/%m/%d') datetime.datetime.strptime("2019/04/30",'%Y/%m/%d') deh dte = datetime.datetime.strptime(S, '%Y/%m/%d') datetime.datetime.strptime(S, '%Y/%m/%d') dte
import datetime
S=input()
dte = datetime.datetime.strptime(S, '%Y/%m/%d')
deh = datetime.datetime.strptime("2019/04/30",'%Y/%m/%d')
if dte<=deh:
  print("Heisei")
else:
  print("TBD")