object Main {
	def main(A:Array[String]){
		val s = new java.util.Scanner(System.in)
		val c=Ordering[Iterable[Int]]
		val d=s.next.split("/").map(_.toInt)
		println(if(c.lt(Seq(1989,1,7),d)&&c.lt(d,Seq(2019,5,1))) "Heisei" else "TBD")
	}
}