s=list(input())
if int(s[5])==1:
    print("TBD")
elif int(s[6])>=5:
    print("TBD")
else:
    print("Heisei")
   
    
    
    
        
        
    
    
    
    
        

      
    
    
        
        
    
    
    
    
         s=list(input()) s list(input()) list input() input if int(s[5])==1:
    print("TBD")
elif int(s[6])>=5:
    print("TBD")
else:
    print("Heisei")
   
    
    
    
        
        
    
    
    
    
        

      
    
    
        
        
    
    
    
    
         int(s[5])==1 int(s[5]) int s[5] s 5 1 print("TBD") print "TBD" elif int(s[6])>=5:
    print("TBD") int(s[6])>=5 int(s[6]) int s[6] s 6 5 print("TBD") print "TBD" print("Heisei") print "Heisei" s=list(input()) list(input()) s
s=list(input())
if int(s[5])==1:
    print("TBD")
elif int(s[6])>=5:
    print("TBD")
else:
    print("Heisei")
   
    
    
    
        
        
    
    
    
    
        

      
    
    
        
        
    
    
    
    
        
