Problem:
 Score : 100 points    Problem Statement You are given a string S as input. This represents a valid date in the year 2019 in the yyyy/mm/dd format. (For example, April 30 , 2019 is represented as 2019/04/30 .)  Write a program that prints Heisei if the date represented by S is not later than April 30 , 2019 , and prints TBD otherwise.      Constraints  S is a string that represents a valid date in the year 2019 in the yyyy/mm/dd format.         Input Input is given from Standard Input in the following format:  S       Output Print Heisei if the date represented by S is not later than April 30 , 2019 , and print TBD otherwise.        Sample Input 1 2019/04/30      Sample Output 1 Heisei       Sample Input 2 2019/11/01      Sample Output 2 TBD

Solution (Python):
"""
author : halo2halo
date : 16, Jan, 2020
"""

import sys
import numpy as np

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
sys.setrecursionlimit(10 ** 7)

Y, M, D = readline().decode('utf8').split('/')
N = int(D) + int(M) * 100 + int(Y) * 10000
print('Heisei' if N <= 20190430 else 'TBD')

Solution (Python):
import re

S = input()
n = int(re.sub(r"/", "", S))
if n <= 20190430:
  print("Heisei")
else:
  print("TBD")

Solution (Python):
S = map(str, str(input()).split('/'))

num = ''
for s in S:
    num += s

if int(num) <= 20190430:
    print('Heisei')
else:
    print('TBD')

Solution (Python):
s = input()
m = int(s[5:7])
d = int(s[8:10])
tt = m * 100 + d
print('Heisei' if tt <= 430 else 'TBD')

Solution (Python):
def main():
    S = list(map(int, input().split('/')))
    if S[0] < 2019:
        print('Heisei')
    elif S[0] == 2019:
        if S[1] <= 4:
            print('Heisei')
        else:
            print('TBD')
    else:
        print('TBD')
 
 
main()

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

Solution (Python):
def main():
    
    

    s = input()
    if int(''.join(s.split('/'))) <= 20190430:
        print('Heisei')
    else:
        print('TBD')
    
if __name__ == '__main__':
    main()

Solution (Python):
import sys

y, m, d = map(int, sys.stdin.readline().split('/'))

def main():
    return 'Heisei' if m <= 4 else 'TBD'

if __name__ == '__main__':
    ans = main()
    print(ans)

Solution (Python):
S = input().split("/")

if S[0] == "2019":
    if int(S[1]) <= 4:
        print("Heisei")

    else:
        print("TBD")

elif int(S[0]) <= 2018:
    print("Heisei")

else:
    print("TBD")

Solution (Python):
from datetime import datetime as dt
S = input()
Sd = dt.strptime(S, '%Y/%m/%d')
Sd1 = dt.strptime("2019/04/30",'%Y/%m/%d')
if Sd > Sd1:
  r = 'TBD'
else:
  r = 'Heisei'
print(r)

Solution (Python):
s = input()
s = s.replace('/', '')
y, m, d = int(s[0:4]), int(s[4:6]), int(s[6:9])

if y<=2019 and m <= 4 and d <= 30:
    print('Heisei')
else:
    print('TBD')

Solution (Python):

import numpy as np


DEBUG = False
dprint = print if DEBUG else lambda x : x

s = input().strip()

date = int(''.join(s.split('/')))
dprint(date)
print('Heisei' if date <= 20190430 else 'TBD')

Solution (Python):
s=input()

print("Heisei" if s<="2019/04/30" else "TBD")

Solution (Python):
s=input()
if int(s[6])<5 and int(s[5])==0:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
s = input()
if(s[5]+s[6] >= '05'):
    print('TBD')
else:
    print('Heisei')

Solution (Python):
s=input()
if int(s[5])*10+int(s[6])<=4:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
n = '2019/04/30'
a = input()
print('Heisei' if a <= n else 'TBD')

Solution (Python):
import datetime
base_date = datetime.datetime.strptime('2019/04/30', "%Y/%m/%d")

S = input()

S_date = datetime.datetime.strptime(S, "%Y/%m/%d")

if S_date <= base_date:
    print('Heisei')
else :
    print('TBD')

Solution (Python):
s = input()

if s<= '2019/04/30':
    print("Heisei")
else:
    print("TBD")

Solution (Python):
a,b,c = map(int,input().split("/"))
if b <= 4:
  print("Heisei")
else:
  print("TBD")

Solution (Python):
s=input()
if s<="2019/04/30":
  print('Heisei')
else:
  print("TBD")

Solution (Python):
s=input()
print('Heisei' if s<="2019/04/30"else "TBD")

Solution (Python):
y,m,d = input().split('/')

if y > '2019':
  print("TBD")
elif y == '2019':
  if m > '04':
    print("TBD")
  elif m == '04':
    if d > '30':
      print("TBD")
    else:
      print("Heisei")
  else:
    print("Heisei")
else:
  print("Heisei")

Solution (Python):
a, b, c=map(int,input().split('/'))
if b<=4:
  print('Heisei')
else:
  print('TBD')

Solution (Python):
def main():
    S = list(map(int, input().split('/')))
    if S[0] < 2019:
        print('Heisei')
    elif S[0] == 2019:
        if S[1] <= 4:
            print('Heisei')
        else:
            print('TBD')
    else:
        print('TBD')


main()

Solution (Python):
y, m, d = input().split("/")

if "2020" <= y:
    print("TBD")
elif y == "2019" and "05" <= m:
    print("TBD")
else:
    print("Heisei")

Solution (Python):
y, m, d = map(lambda x: int(x), input().split('/'))
if m <= 4:
  print('Heisei')
else:
  print('TBD')

Solution (Python):
import datetime

S = input()
sdt = datetime.datetime.strptime(S, '%Y/%m/%d')
hdt = datetime.datetime.strptime('2019/04/30', '%Y/%m/%d')

print('TBD' if sdt > hdt else 'Heisei')

Solution (Python):
S=input().split("/")
if int(S[0])<=2018:
  print("Heisei")
elif int(S[0])==2019 and int(S[1])<=4:
  print("Heisei")
else:
  print("TBD")

Solution (Python):
import sys
sys.setrecursionlimit(10**9)
INF=10**18
MOD=10**9+7
def input():
    return sys.stdin.readline().rstrip()

def main():
    l=list(map(int,input().split('/')))
    if l[0]<2019 or l[1]<=4:
        print('Heisei')
    else:
        print('TBD')

if __name__ == '__main__':
    main()

Solution (Python):
S = input()

if S <= '2019/04/30':
    print('Heisei')
else:
    print('TBD')

Solution (Python):
y, m, d = map(int, input().split('/'))

if (m < 4 or (m == 4 and d <= 30)):
   print('Heisei')
else:
   print('TBD')

Solution (Python):
print('Heisei' if input()<='2019/04/30' else 'TBD')

Solution (Python):
s=input()
a=int(s[5:7])
if 0<a<5:
  print('Heisei')
else:
  print('TBD')

Solution (Python):
a,b,c=map(int,input().split("/"))
if a <= 2019 and b <= 4 and c <= 30:
  print('Heisei')
else:print('TBD')

Solution (Python):
print('Heisei' if int(input()[5:7]) <= 4 else 'TBD')

Solution (Python):
s = input()

year = int(s[:4])
month = int(s[5:7])
day = int(s[8:])

if year == 2019 and month == 4 and day <= 30:
    print("Heisei")
elif year == 2019 and month < 4:
    print("Heisei")
elif year <= 2018:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
s = input()
if s <= "2019/04/30":
  print("Heisei")
else:
  print("TBD")

Solution (Python):
s = input()

if int(s[0:4]) <= 2019 and int(s[5:7]) <= 4 and int(s[8:10]) <= 30:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
S = input()
print('Heisei' if S <= '2019/04/30' else 'TBD')

Solution (Python):
s = list(map(int, input().split('/')))

if s[0] >= 2019:
    if s[1] > 4:
        print('TBD')
    else:
        print('Heisei')
else:
    print('Heisei')

Solution (Python):
a,b,c=map(int,input().split('/'))
if a<=2019 and b<=4:
  print('Heisei')
else:
  print('TBD')

Solution (Python):
S = input()
YMD = S.split('/')
MD = int(''.join(YMD[1:]))

ans = 'Heisei' if MD <= 430 else 'TBD'
print(ans)

Solution (Python):
s = input()
print("Heisei" if s <= "2019/04/30" else "TBD")

Solution (Python):
s=input()
a=list(map(int,s.split("/")))
if a[0]<2019:
  print("Heisei")
  exit()
if a[0]==2019 and a[1]<=4:
  print("Heisei")
  exit()
print("TBD")

Solution (Python):
S = input()
YMD = S.split('/')
MD = int(''.join(YMD[1:]))

ans = 'Heisei' if MD <= 430 else 'TBD'
print(ans)

Solution (Python):
S = input()
if int(S[5:7]) <= 4:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
s=input()
y=int(s[:4])
m=int(s[5:7])
d=int(s[8:])
if y>2019:
    print('TBD')
elif m>4:
    print('TBD')
else:
    print('Heisei')

Solution (Python):
s=input()
y=int(s[:4])
m=int(s[5:7])
d=int(s[8:])
if y>2019:
    print('TBD')
elif m>4:
    print('TBD')
elif d>30:
    print('TBD')
else:
    print('Heisei')

Solution (Python):
y,m,d = input().split('/')
print("Heisei" if int(y+m+d) <= 20190430 else "TBD")

Solution (Python):
s=list(map(int,input().split('/')))
if s[0]<2019:
    print('Heisei')
elif s[0]==2019 and s[1]<=4 and s[2]<=30:
    print('Heisei')
else:
    print('TBD')

Solution (Python):
S = input()
print("TBD" if int(S[5:7]) > 4 else "Heisei")

Solution (Python):
y, m, d = list(map(int, input().split('/')))
if m <= 4:
  print('Heisei')
else:
  print('TBD')

Solution (Python):
y,m,d=input().split("/")
print("Heisei" if int(y+m+d) <= 20190430 else "TBD")

Solution (Python):
s = list(map(int,input().split('/')))
if s[0] < 2019:
    print('Heisei')
elif s[1] <= 4:
    print('Heisei')
else:
    print('TBD')

Solution (Python):
print("Heisei" if input()<="2019/04/30" else "TBD")

Solution (Python):
n = input()
print('Heisei' if n <= '2019/04/30' else 'TBD')

Solution (Python):
y, m, d = map(int, input().split("/"))

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")

Solution (Python):
y, m, d = map(int, input().split('/'))
print('Heisei') if y <= 2019 and m <= 4 and d <= 30 else print('TBD')

Solution (Python):
Y, M, D = map(str, input().split("/"))
s = ''.join([Y,M,D])

if int(s)>20190430:
    print("TBD")
else:
    print("Heisei")

Solution (Python):
S=input()

if int(S[0:4])<=2018:
  print("Heisei")
elif int(S[0:4])>2019:
  print("TBD")
else:
  if int(S[5:7])<=4:
    print("Heisei")
  else:
    print("TBD")

Solution (Python):
y,m,d=map(int,input().split('/'))
if y>=2019 and m>=5:
    print('TBD')
else:
    print('Heisei')

Solution (Python):
INT = lambda: int(input())
INTM = lambda: map(int,input().split())
STRM = lambda: map(str,input().split())
STR = lambda: str(input())
LIST = lambda: list(map(int,input().split()))
LISTS = lambda: list(map(str,input().split()))
def do():
    s=STR()
    if s[5]=='0'and int(s[6])<=4:
        print('Heisei')
    else:
        print('TBD')
if __name__ == '__main__':
    do()

Solution (Python):
import bisect
import cmath
import heapq
import itertools
import math
import operator
import os
import re
import string
import sys
from collections import Counter, deque, defaultdict
from copy import deepcopy
from decimal import Decimal
from fractions import gcd
from functools import lru_cache, reduce
from operator import itemgetter, mul, add, xor

import numpy as np

if os.getenv("LOCAL"):
    sys.stdin = open("_in.txt", "r")

sys.setrecursionlimit(10 ** 9)
INF = float("inf")
IINF = 10 ** 18
MOD = 10 ** 9 + 7



S = sys.stdin.buffer.readline().decode().rstrip()

if S <= '2019/04/30':
    print('Heisei')
else:
    print('TBD')

Solution (Python):
n = input()
if n <= "2019/04/30":
    print("Heisei")
else:
    print("TBD")

Solution (Python):
s = input().replace('/','')
ans = "TBD" if int(s)>20190430 else "Heisei"
print(ans)

Solution (Python):
S=list(map(int,input().split("/")))
if S[0]>2019:
    print("TBD")
elif S[0]<2019:
    print("Heisei")
else:
    if S[1]<4:
        print("Heisei")
    elif S[1]>4:
        print("TBD")
    else:
        if S[2]<=30:
            print("Heisei")
        else:
            print("TBD")

Solution (Python):
import datetime
S = input()
dte = datetime.datetime.strptime(S, '%Y/%m/%d')
dte2 = datetime.datetime(2019, 4, 30)
if dte <= dte2:
    print('Heisei')
else:
    print('TBD')

Solution (Python):
S = input()
if(int(S[0:3]) <= 2019 and int(S[5:7]) <= 4 and int(S[8:10])<=30):
	print("Heisei")
else:
	print("TBD")

Solution (Python):
s = input().split("/")

if int(s[1]) <= 4:
    ans = "Heisei"
else:
    ans = "TBD"

print(ans)

Solution (Python):
def solve():
    yyyy, mm, dd = map(int, input().split('/'))
    if mm <= 4:
        print('Heisei')
    else:
        print('TBD')


if __name__ == '__main__':
    solve()

Solution (Python):
s = input()
y, m, d = map(int, s.split(sep="/"))
if y > 2019:
    print("TBD")
elif y < 2019:
    print("Heisei")
else:
    if m > 4:
        print("TBD")
    elif m < 4:
        print("Heisei")
    else:
        if d <= 30:
            print("Heisei")
        else:
            print("TBD")

Solution (Python):
a,b,c=map(int,input().split('/'))
if(a==2019):
    if(b<=4):
        print("Heisei")
    else:
        print("TBD")
elif(a<2019):
    print("Heisei")
else:
    print("TBD")

Solution (Python):
y, m, d = map(int, input().split("/"))
print('Heisei' if y*10000 + m*100 + d <= 20190430 else "TBD")

Solution (Python):
s=input()
if int(s[5:7]+s[8:10])<=430:
  print('Heisei')
else:
  print('TBD')

Solution (Python):
import math

s = input()
print("Heisei" if s <= "2019/04/30" else "TBD")

Solution (Python):
import datetime

S = input()
date1 = datetime.datetime.strptime(S, "%Y/%m/%d")
date2 = datetime.datetime(2019, 4, 30, 00, 00, 00)

if date1 <= date2:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
s = input()

if s <= '2019/04/30':
    print('Heisei') 
else:
    print('TBD')

Solution (Python):
y,m,d = map(int, input().split("/"))
if y > 2018 and m > 4 :
    print("TBD")
else:
    print("Heisei")

Solution (Python):
Y,M,D = map(int, input().split("/"))
if Y<=2018:
  print("Heisei")
elif Y==2019 and M<=4:
  print("Heisei")
else:
  print("TBD")

Solution (Python):
s = input()
s1 = [s[0], s[1], s[2], s[3]]
s2 = [s[5], s[6]]

t1 = int(''.join(s1))
t2 = int(''.join(s2))

if t1 > 2019:
    print('TBD')

elif t1 == 2019 and t2 > 4:
    print('TBD')

else:
    print('Heisei')

Solution (Python):
import datetime
*s, = map(int, input().split("/"))

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

print("Heisei" if datetime.datetime(s[0], s[1], s[2]) <= ref else "TBD")

Solution (Python):

S = list(map(int, input().split('/')))

if S[0] <= 2018 or S[0] == 2019 and S[1] <= 4 and S[2] <= 30:
    print('Heisei')
else:
    print('TBD')

Solution (Python):
y, m, d = map( int, input().split("/") )
if y < 2019 or ( y == 2019 and m <= 4 ) :
   print( "Heisei" )
else : 
   print( "TBD" )

Solution (Python):
Y, M, D = list(map(int, input().split("/")))
if M == 4 and D == 31 :
	print("TBD")
elif M <= 4 :
	print("Heisei")
else :
	print("TBD")

Solution (Python):
S = input()
ans="TBD"
if S[5]=="0":
  if S[6] == "1" or S[6] == "2" or S[6] == "3" or S[6] == "4":
    ans = "Heisei"
print(ans)

Solution (Python):
a = input()

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

Solution (Python):
import datetime

a = input()
b = datetime.datetime.strptime(a, '%Y/%m/%d')
c = datetime.datetime(2019, 4, 30)

if b <= c:
	print('Heisei')
else:
	print('TBD')

Solution (Python):
S = input()
y, m, d = map(int, S.split('/'))
if m <= 4:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
S = input()
print('Heisei' if S <= '2019/04/30' else 'TBD')

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import permutations, combinations, product, accumulate
from operator import itemgetter, mul
from copy import deepcopy,copy
from string import ascii_lowercase, ascii_uppercase, digits
from fractions import gcd

def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

def main():
	s = list(input().split('/'))
	s = [int(x) for x in s]
	
	if s[0] <= 2019:
		if s[1] <= 4:
			if s[2] <= 30:
				print('Heisei')
			else:
				print('TBD')
		else:
			print('TBD')
	else:
		print('TBD')

if __name__=='__main__':
	main()

Solution (Python):
a=input()

if int(a[5]+a[6])<=4:
  print("Heisei")
else:
  print("TBD")

Solution (Python):
y, m, d = map(int, input().split("/"))
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")

Solution (Python):
import re
s=input()
if int(re.match(r'\d{4}/(\d{2})/\d{2}',s).group(1))>4:
    print('TBD')
else:
    print('Heisei')

Solution (Python):
S = input()
YMD = S.split('/')
MD = int(''.join(YMD[1:]))
 
answer = 'Heisei' if MD <= 430 else 'TBD'
print(answer)

Solution (Python):
s = input()
List = [int(x) for x in s.split("/")]
if List[0]>= 2019 and List[1]>=5:
    print("TBD")
else:
    print("Heisei")

Solution (Python):
s=input()
if int(s[:4])<=2019:
    if int(s[5:7])<=4:
        if int(s[8:]):
            print("Heisei")
            exit()
print("TBD")

Solution (Python):
S = input()
wk = int(S[:4]+S[5:7]+S[8:10])
if wk<=20190430:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
y, m, d = map(int, input().split('/'))
if y < 2019 or (y == 2019 and m <= 4):
    print('Heisei')
else:
    print('TBD')

Solution (Python):
s = input()
print('Heisei' if s <= '2019/04/30' else 'TBD')

Solution (Python):
i = input()
print("Heisei" if int(i[5]+i[6]+i[8]+i[9]) <= 430 else "TBD" )

Solution (Python):
d=input()
if int(d[0:4])<2019:
  print('Heisei')
elif int(d[0:4])==2019 and int(d[5:7])<=4:
  print('Heisei')
else:
  print('TBD')

Solution (Python):
s = input()

ans = 'TBD'

if int(s[:4])<2019:
    ans='Heisei'
elif int(s[:4])==2019:
    if int(s[5:7])<5:
        ans='Heisei'

print(ans)

Solution (Python):
s=input()
if int(s[5:7])>4:
  print("TBD")
else:
  print("Heisei")

Solution (Python):
a, b, c = map(int, input().split("/"))
if b <= 4:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
a=input()
b=a.split("/")
if int(b[1])>=5:
    print("TBD")
else:
    print("Heisei")

Solution (Python):
def p_a():
    y, m, d = map(int, input().split("/"))
    ans = "Heisei"
    if y == 2019:
        if m > 4:
            ans = "TBD"
    elif y > 2019:
        ans = "TBD"
    print(ans)
    
p_a()

Solution (Python):
s = list(map(int,input().split("/")))

s = s[0] * 10000 + s[1] * 100 + s[2]
print("TBD") if s > 20190430 else print("Heisei")

Solution (Python):
s = input()
rei = "2019/04/30"
if 4 < int(s[5:7]):
	print("TBD")
else:
    print("Heisei")

Solution (Python):
yr, mn, dy = [int(x) for x in input().split("/")]

if yr <= 2019 and mn <= 4 and dy <=30:
  print("Heisei")
else:
  print("TBD")

Solution (Python):
import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

S = [int(x) for x in input().rstrip().split("/")]

if S[0] == 2019 and S[1] > 4:
    print("TBD")
elif S[0] > 2019:
    print("TBD")
else:
    print("Heisei")

Solution (Python):
import sys
input = sys.stdin.readline
def print_ans(S):
    """Test Case
    >>> print_ans("2019/04/30")
    Heisei
    >>> print_ans("2019/11/01")
    TBD
    """
    S = int("".join(S.split("/")))
    if S <= 20190430:
        print("Heisei")
    else:
        print("TBD")


if __name__ == '__main__':
    S = input().rstrip()
    print_ans(S)

Solution (Python):
S = input()
num = int(''.join(S.split('/')))
if  num > 20190430:
    print('TBD')
else:
    print('Heisei')

Solution (Python):
s = input()
y = int(s[:4])
m = int(s[5:7])
d = int(s[-2:])
if y < 2019:
    print("Heisei")
elif y == 2019 and m < 5:
    print("Heisei")
elif y == 2019 and m == 4 and d == 30:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
n=int(input()[5:7])
if n<5:
  print("Heisei")
else:
  print("TBD")

Solution (Python):
def examA():
    S = SI()
    M = int(S[5:7]);  D = int(S[8:10])
    if M<=4:
        ans = "Heisei"
    else:
        ans = "TBD"
    print(ans)
    return




import sys,copy,bisect,itertools,heapq,math
from heapq import heappop,heappush,heapify
from collections import Counter,defaultdict,deque
def I(): return int(sys.stdin.readline())
def LI(): return list(map(int,sys.stdin.readline().split()))
def LSI(): return list(map(str,sys.stdin.readline().split()))
def LS(): return sys.stdin.readline().split()
def SI(): return sys.stdin.readline().strip()
mod = 10**9 + 7
inf = float('inf')

if __name__ == '__main__':
    examA()

Solution (Python):
S=list(input())
S.remove("/")
S.remove("/")

T=int(''.join(S))

if T<=20190430:
  print("Heisei")
else:
  print("TBD")

Solution (Python):
import datetime
d = input()
df = datetime.datetime.strptime(d, "%Y/%m/%d")
print("Heisei" if df < datetime.datetime(2019, 4, 30, 0, 0, 1) else "TBD")

Solution (Python):
import math
import heapq
import sys
from collections import Counter
import numpy as np
import datetime
from decimal import Decimal, ROUND_HALF_UP, ROUND_HALF_EVEN





S=input()

a=datetime.datetime(int(S[:4]), int(S[5:7]), int(S[8:10]))        
b=datetime.datetime(2019,4,30)

if a<=b:
    print('Heisei')
else:
    print('TBD')

Solution (Python):
S=list(input())
S.remove("/")
S.remove("/")
st=int("".join(S))
if st <=20190430:
  print("Heisei")
else:
  print("TBD")

Solution (Python):

from heapq import heappush, heappop, heapify
from collections import deque, defaultdict, Counter
import itertools
from itertools import permutations, combinations
import sys
import bisect
import string
import math
import time
from fractions import gcd



def I(): return int(input())


def MI(): return map(int, input().split())


def LI(): return [int(i) for i in input().split()]


def LI_(): return [int(i)-1 for i in input().split()]


def StoI(): return [ord(i)-97 for i in input()]


def ItoS(nn): return chr(nn+97)


def input(): return sys.stdin.readline().rstrip()


def show(*inp, end='\n'):
    if show_flg:
        print(*inp, end=end)


YN = ['Yes', 'No']
MOD = 10**9+7
inf = float('inf')
l_alp = string.ascii_lowercase
u_alp = string.ascii_uppercase
ts = time.time()
sys.setrecursionlimit(10**6)


show_flg = False



def main():
    S = input()

    if S <= '2019/04/30':
        print('Heisei')
    else:
        print('TBD')


if __name__ == '__main__':
    main()

Solution (Python):
y,m,d = map(int,input().split('/'))

if m>4:
    print("TBD")
else:
    print("Heisei")

Solution (Python):
y,m,d=map(int,input().split("/"))
if y>=2019 and m>=5 :
    print("TBD")
else:
    print("Heisei")

Solution (Python):
import datetime
s=input()
a=datetime.datetime.strptime(s,'%Y/%m/%d')
b=datetime.datetime.strptime('2019/04/30','%Y/%m/%d')

if a <= b:
    print('Heisei')
else:
    print('TBD')

Solution (Python):
S = input()

if int(S.replace("/", "")) <= 20190430:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
import datetime
S = input()

formatted_s = datetime.datetime.strptime(S, "%Y/%m/%d")
heisei = datetime.datetime(2019, 4, 30)

if formatted_s <= heisei:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
import datetime

S = input()
dt = datetime.datetime.strptime(S, "%Y/%m/%d")
THRESHOLD = datetime.datetime(2019, 4, 30)

if dt <= THRESHOLD:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
import os, sys, re, math

S = input()

if S <= '2019/04/30':
    print('Heisei')
else:
    print('TBD')

Solution (Python):
import datetime

y, m, d = [int(i) for i in input().split('/')]

comp1 = datetime.datetime(2019, 4, 30)
comp2 = datetime.datetime(y, m, d)

if comp2 <= comp1:
	print ('Heisei')
else:
	print ('TBD')

Solution (Python):
y, m, d  = [int(s) for s in input().split('/')]

print('Heisei' if 20190430 >= y*10000+m*100+d else 'TBD')

Solution (Python):
import os, sys, re, math

S = input()

[y, m, d] = [int(t) for t in S.split('/')]

if y < 2019 or (y == 2019 and m <= 4):
    print ('Heisei')
else:
    print ('TBD')

Solution (Python):
y,m,d = list(map(int, input().split('/')))
if y > 2019 or y == 2019 and m >= 5:
  print('TBD')
else:
  print('Heisei')

Solution (Python):

import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**6)

s = input()[:-1]
print('TBD' if int(s[5:7]) > 4 else 'Heisei')

Solution (Python):
print('Heisei' if input() <= '2019/04/30' else 'TBD')

Solution (Python):
s = input().replace('/','')
if int(s) <= 20190430:
    print('Heisei')
else:
    print('TBD')

Solution (Python):
y,m,d = map(int,input().split('/'))
print('Heisei' if m <=4 else 'TBD')

Solution (Python):
s = input()

month = int(s[5:7])

print("Heisei" if month <= 4 else "TBD")

Solution (Python):
S=map(int,input().split("/"))
A=[]
for i in S:
    A.append(i)
if A[1]>4:
    print("TBD")
else:
    print("Heisei")

Solution (Python):





S = list(input())


if S[5]=='1' or (S[6] >= '5' or S[5] == '1'):
    print("TBD")
else:
    print("Heisei")

Solution (Python):
S = input()

li=S.split('/')

if int(li[1])<= 4:
  print('Heisei')
else:
  print('TBD')

Solution (Python):

import math
import datetime





S = str(input())
H = "2019/04/30"

dateS = datetime.datetime.strptime(S, '%Y/%m/%d')
dateH = datetime.datetime.strptime(H, '%Y/%m/%d')

if dateS <= dateH :
  print ("Heisei")
else :
  print("TBD")

Solution (Python):
S = input()

if S <= "2019/04/30":
  print("Heisei")
else:
  print("TBD")

Solution (Python):
d = list(map(int, input().split("/")))

if d[1] < 5:
  print("Heisei")
else:
  print("TBD")

Solution (Python):
p=input()
x=int((p[0:4])+(p[5:7])+(p[8:]))
if (x<=20190430):
  print("Heisei")
else:
  print("TBD")

Solution (Python):
S = input().split("/")
if int(S[0]) < 2019:
    print("Heisei")
else:
    if int(S[1]) >= 5:
        print("TBD")
    else:
        print("Heisei")

Solution (Python):
s=list(map(int,input().split('/')))
if s[0] <= 2019 and s[1] <= 4 and s[2] <= 30:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
print( "Heisei" if input() <= "2019/04/30" else "TBD")

Solution (Python):
y,m,d=map(int,input().split("/"))
if (2019<y or (2019==y and 4<m) | (2019==y and m==4 and 30<d)):
    print("TBD")
else:
    print("Heisei")

Solution (Python):
from datetime import datetime as dt
heisei = dt.strptime("2019/04/30",'%Y/%m/%d')
s = input()
sdate = dt.strptime(s,'%Y/%m/%d')
if sdate <= heisei:
  print("Heisei")
else:
  print("TBD")

Solution (Python):
s=input()
print("Heisei" if s<="2019/04/30" else "TBD")

Solution (Python):
y,m,d=map(int,input().split("/"))
print("Heisei" if y<2018 or y==2019 and m<5 else "TBD")

Solution (Python):
y, m, d = map(int, input().split('/'))

if y<2019:
  print("Heisei")
elif y == 2019:
  if m <5:
    print("Heisei")
  else:
    print("TBD")
else:
  print("TBD")

Solution (Python):
S = input()
y=int(S[0:4]+S[5:7]+S[8:10])

if y > 20190430:
    print("TBD")
else:
    print("Heisei")

Solution (Python):
S = input() 

if S <= "2019/04/30":
    print("Heisei")
else:
    print("TBD")

Solution (Python):
S=input()
y=int(S[0:4]+S[5:7]+S[8:10])
if y > 20190430:
  print("TBD")
else:
  print("Heisei")

Solution (Python):
n = input()
n1 = int(n[0:4]+n[5:7]+n[8:10])
if n1 > 20190430:
    print("TBD")
else:
    print("Heisei")

Solution (Python):
s = input()

if int(s[5:7]) > 4:
    print('TBD')
else:
    print('Heisei')

Solution (Python):
A,B,C = (int(i) for i in input().split('/'))

if B > 4:
    print('TBD')
else:
    print('Heisei')

Solution (Python):
s = input().split('/')
if int(s[0]) > 2019:
    print('TBD')
if int(s[0]) < 2019:
    print('Heisei')
else:
    if int(s[1]) > 4:
        print('TBD')
    else:
        print('Heisei')

Solution (Python):
x, y, z=list(map(int, input().split("/")))
if y>=5:
  print("TBD")
else:
  print("Heisei")

Solution (Python):
s = input()
if int(s.replace('/', '')) <= 20190430:
    print('Heisei')
else:
    print('TBD')

Solution (Python):
s= input()
if int(s[5:7])>=5:
    print("TBD")
else:
    print("Heisei")

Solution (Python):
s = input()
y = int(s[:4])
m = int(s[5:7])
d = int(s[8:])
flag = 1
if y > 2019:
    flag = 0
elif y == 2019:
    if m >= 5:
        flag = 0


if flag == 1:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
list1 = input()

yy = int(list1[:4])
mm = int(list1[5:7])
dd = int(list1[8:])

if yy >= 2019:
    if yy == 2019 and mm <= 4:
        print("Heisei")
        exit()
    print("TBD")
    exit()
print("Heisei")

Solution (Python):
s=input()
print("Heisei" if s <= "2019/04/30" else "TBD")

Solution (Python):
s=input()
if int(s[5:7])>4:
  print("TBD")
else:
  print("Heisei")

Solution (Python):
S=list(map(str,input()))
nen=0
tsuki=0
nen=int(S[0]+S[1]+S[2]+S[3])
tsuki=int(S[5]+S[6])
if nen<2019:
  print("Heisei")
elif nen>2019:
  print("TBD")
elif nen==2019 and tsuki<5:
  print("Heisei")
else:
  print("TBD")

Solution (Python):
s = [int(i) for i in input().split('/')]

if s[0] <= 2019 and s[1] <= 4 and s[-1] <= 30:
  print('Heisei')
else:
  print('TBD')

Solution (Python):
s = input()
print('Heisei' if s <= '2019/04/30' else 'TBD')

Solution (Python):

S = input()
if S[5:7] == "01" or S[5:7] == "02" or S[5:7] == "03" or S[5:7] == "04":
    print("Heisei")
else:
    print("TBD")

Solution (Python):
s = input()
s = int(s.replace("/", ""))
if s <= 20190430 :
    print("Heisei")
else :
    print("TBD")

Solution (Python):
s = input()
if int(s[5:7])<= 4:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
S = input()
if int(S[5:7]) <= 4:
	print('Heisei')
else:
	print('TBD')

Solution (Python):
s=int(input()[5:7])
if s<5:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
S = list(map(int, input().split('/')))
if S[0] < 2019:
  print('Heisei')
elif S[0] <= 2019 and S[1] <= 4:
  print('Heisei')
else:
  print('TBD')

Solution (Python):
import datetime

def main():
    y,m,d = map(int, input().split('/'))

    diff = datetime.date(2019,4,30)-datetime.date(y,m, d)
    if diff.days >= 0:
        print('Heisei')
    else:
        print('TBD')

if __name__ == '__main__':
    main()

Solution (Python):
import datetime

def main():
    S = input()
    
    year = int(S[0:4])
    month= int(S[5:7])
    day = int(S[8:10])
    diff = datetime.date(2019,4,30)-datetime.date(year,month, day)
    if diff.days >= 0:
        print('Heisei')
    else:
        print('TBD')

if __name__ == '__main__':
    main()

Solution (Python):
s = input()

a = int("".join(s.split("/")))

if a <= 20190430:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
S = list(map(int, input().split("/")))
ans = True
if S[0] > 2019:
    ans = False
elif S[0] == 2019 and S[1] > 4:
    ans = False

if ans:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
date = int(input().replace("/", ""))
if date <= 20190430:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
date = input()

import re
date_num = int(re.sub("\D", "", date))

if date_num <= 20190430:
    print("Heisei")
else:
    print("TBD")

Solution (Python):

import sys










def main():
    s = sys.stdin.readline().rstrip()
    mm = int(s[5:7])
    dd = int(s[8:10])
    if mm <= 4 and dd <= 30:
        print('Heisei')
    else:
        print('TBD')


if __name__ == "__main__":
    main()

Solution (Python):
date = input()

import re
date_num = int(re.sub("\D" , "" , date))

if date_num <= 20190430:
    print("Heisei")
else:
    print("TBD")

Solution (Python):
S = list(map(int,input().split("/")))
ans = False
if S[0] > 2019:
    ans = True
elif S[0] >= 2019 and S[1] > 4:
    ans = True
elif S[0] >= 2019 and S[1] >= 4 and S[2] > 30:
    ans = True

if ans == True:
    print("TBD")
else:
    print("Heisei")

Solution (Python):
s=input()
S=""
if int(s[6])<=4:
  if s[5]=="0":
    print("Heisei")
  else:
    print("TBD")
else:
  print("TBD")

Solution (Python):
n=str(input())
if int(n[0:4])>2019:
    print("TBD")
elif int(n[0:4])<2019:
    print("Heisei")
elif int(n[0:4])==2019:
    if int(n[5:7])>4:
        print("TBD")
    elif int(n[5:7])<=4:
        print("Heisei")

Solution (Python):
s = input()

y,m,d = map(int, s.split("/"))

if y<2019:
  print("Heisei")
elif y==2019 and m<4:
  print("Heisei")
elif m==4 and d<=30:
  print("Heisei")
else:
  print("TBD")

Solution (Python):
y,m,d=map(int,input().split('/'))
if y >= 2019 and m >= 5:
    print('TBD')
else:
    print('Heisei')