import bisect,collections,copy,heapq,itertools,math,string
import sys
def S(): return sys.stdin.readline().rstrip()
def M(): return map(int,sys.stdin.readline().rstrip().split())
def I(): return int(sys.stdin.readline().rstrip())
def LI(): return list(map(int,sys.stdin.readline().rstrip().split()))
def LS(): return list(sys.stdin.readline().rstrip().split())
s = S()
if s[5] == '1':
    print('TBD')
elif int(s[6]) < 5:
    print('Heisei')
else:
    print('TBD') import bisect,collections,copy,heapq,itertools,math,string bisect collections copy heapq itertools math string import sys sys def S(): return sys.stdin.readline().rstrip() S def M(): return map(int,sys.stdin.readline().rstrip().split()) M def I(): return int(sys.stdin.readline().rstrip()) I def LI(): return list(map(int,sys.stdin.readline().rstrip().split())) LI def LS(): return list(sys.stdin.readline().rstrip().split()) LS s = S() s S() S if s[5] == '1':
    print('TBD')
elif int(s[6]) < 5:
    print('Heisei')
else:
    print('TBD') s[5] == '1' s[5] s 5 '1' print('TBD') print 'TBD' elif int(s[6]) < 5:
    print('Heisei') int(s[6]) < 5 int(s[6]) int s[6] s 6 5 print('Heisei') print 'Heisei' print('TBD') print 'TBD' def LI(): return list(map(int,sys.stdin.readline().rstrip().split())) def LI(): return list(map(int,sys.stdin.readline().rstrip().split())) LI def M(): return map(int,sys.stdin.readline().rstrip().split()) def M(): return map(int,sys.stdin.readline().rstrip().split()) M def I(): return int(sys.stdin.readline().rstrip()) def I(): return int(sys.stdin.readline().rstrip()) I def LS(): return list(sys.stdin.readline().rstrip().split()) def LS(): return list(sys.stdin.readline().rstrip().split()) LS s = S() S() s def S(): return sys.stdin.readline().rstrip() def S(): return sys.stdin.readline().rstrip() S
import bisect,collections,copy,heapq,itertools,math,string
import sys
def S(): return sys.stdin.readline().rstrip()
def M(): return map(int,sys.stdin.readline().rstrip().split())
def I(): return int(sys.stdin.readline().rstrip())
def LI(): return list(map(int,sys.stdin.readline().rstrip().split()))
def LS(): return list(sys.stdin.readline().rstrip().split())
s = S()
if s[5] == '1':
    print('TBD')
elif int(s[6]) < 5:
    print('Heisei')
else:
    print('TBD')