s = input()
year = int(s[:4])
month = int(s[5:7])
date = int(s[8:10])

if year <= 2019:
    if month <= 4:
        print('Heisei')
    else:
        print('TBD')
else:
    print('TBD') s = input() s input() input year = int(s[:4]) year int(s[:4]) int s[:4] s :4 4 month = int(s[5:7]) month int(s[5:7]) int s[5:7] s 5:7 5 7 date = int(s[8:10]) date int(s[8:10]) int s[8:10] s 8:10 8 10 if year <= 2019:
    if month <= 4:
        print('Heisei')
    else:
        print('TBD')
else:
    print('TBD') year <= 2019 year 2019 if month <= 4:
        print('Heisei')
    else:
        print('TBD') month <= 4 month 4 print('Heisei') print 'Heisei' print('TBD') print 'TBD' print('TBD') print 'TBD' year = int(s[:4]) int(s[:4]) year month = int(s[5:7]) int(s[5:7]) month date = int(s[8:10]) int(s[8:10]) date s = input() input() s
s = input()
year = int(s[:4])
month = int(s[5:7])
date = int(s[8:10])

if year <= 2019:
    if month <= 4:
        print('Heisei')
    else:
        print('TBD')
else:
    print('TBD')