def main():
    s = list(map(int, input().split("/")))
    if s[0] > 2019:
        print("TBD")
        return
    
    if s[1] > 4:
        print("TBD")
        return

    # 必要??
    if s[2] > 30:
        print("TBD")
        return

    print("Heisei")

if __name__ == "__main__":
    main() def main():
    s = list(map(int, input().split("/")))
    if s[0] > 2019:
        print("TBD")
        return
    
    if s[1] > 4:
        print("TBD")
        return

    # 必要??
    if s[2] > 30:
        print("TBD")
        return

    print("Heisei") main 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")
        return
    
     s[0] > 2019 s[0] s 0 2019 print("TBD") print "TBD" return if s[1] > 4:
        print("TBD")
        return

    # 必要??
     s[1] > 4 s[1] s 1 4 print("TBD") print "TBD" return if s[2] > 30:
        print("TBD")
        return

     s[2] > 30 s[2] s 2 30 print("TBD") print "TBD" return print("Heisei") print "Heisei" if __name__ == "__main__":
    main() __name__ == "__main__" __name__ "__main__" main() main def main():
    s = list(map(int, input().split("/")))
    if s[0] > 2019:
        print("TBD")
        return
    
    if s[1] > 4:
        print("TBD")
        return

    # 必要??
    if s[2] > 30:
        print("TBD")
        return

    print("Heisei") def main():
    s = list(map(int, input().split("/")))
    if s[0] > 2019:
        print("TBD")
        return
    
    if s[1] > 4:
        print("TBD")
        return

    # 必要??
    if s[2] > 30:
        print("TBD")
        return

    print("Heisei") main
def main():
    s = list(map(int, input().split("/")))
    if s[0] > 2019:
        print("TBD")
        return
    
    if s[1] > 4:
        print("TBD")
        return

    # 必要??
    if s[2] > 30:
        print("TBD")
        return

    print("Heisei")

if __name__ == "__main__":
    main()
