S=input()
if int(S[:4])<2019:
  print('Heisei')
elif int(S[:4])==2019 and int(S[5:7])<4:
  print('Heisei')
elif int(S[:4])==2019 and int(S[5:7])==4 and int(S[8:10])<=30:
  print('Heisei')
else:
  print('TBD') S=input() S input() input if int(S[:4])<2019:
  print('Heisei')
elif int(S[:4])==2019 and int(S[5:7])<4:
  print('Heisei')
elif int(S[:4])==2019 and int(S[5:7])==4 and int(S[8:10])<=30:
  print('Heisei')
else:
  print('TBD') int(S[:4])<2019 int(S[:4]) int S[:4] S :4 4 2019 print('Heisei') print 'Heisei' elif int(S[:4])==2019 and int(S[5:7])<4:
  print('Heisei') int(S[:4])==2019 and int(S[5:7])<4 int(S[:4])==2019 int(S[:4]) int S[:4] S :4 4 2019 int(S[5:7])<4 int(S[5:7]) int S[5:7] S 5:7 5 7 4 print('Heisei') print 'Heisei' elif int(S[:4])==2019 and int(S[5:7])==4 and int(S[8:10])<=30:
  print('Heisei') int(S[:4])==2019 and int(S[5:7])==4 and int(S[8:10])<=30 int(S[:4])==2019 and int(S[5:7])==4 int(S[:4])==2019 int(S[:4]) int S[:4] S :4 4 2019 int(S[5:7])==4 int(S[5:7]) int S[5:7] S 5:7 5 7 4 int(S[8:10])<=30 int(S[8:10]) int S[8:10] S 8:10 8 10 30 print('Heisei') print 'Heisei' print('TBD') print 'TBD' S=input() input() S
S=input()
if int(S[:4])<2019:
  print('Heisei')
elif int(S[:4])==2019 and int(S[5:7])<4:
  print('Heisei')
elif int(S[:4])==2019 and int(S[5:7])==4 and int(S[8:10])<=30:
  print('Heisei')
else:
  print('TBD')