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