a,b,c=map(int,input().split('/'));print(['TBD','Heisei'][a<=2019 and b<=4 and c<=30])
12ad023c0e8fe0dc972de9078af801df1da9f918
<mask token>

<mask token>
print(['TBD', 'Heisei'][a <= 2019 and b <= 4 and c <= 30])

a, b, c = map(int, input().split('/'))
print(['TBD', 'Heisei'][a <= 2019 and b <= 4 and c <= 30])

a,b,c=map(int,input().split('/'));print(['TBD','Heisei'][a<=2019 and b<=4 and c<=30])