output_description: Print `Heisei` if the date represented by S is not later than April 30, 2019,
  and print `TBD` otherwise.
  
  * * *
input_description: Input is given from Standard Input in the following format:
  
      
      
      S
attempt: #coding:utf-8
  import sys
  
  BAMB_NUM = 0
  BAMB_A = 0
  BAMB_B = 0
  BAMB_C = 0
  BAMB_LIST = []
  
  def calcMP(idx, lenA, lenB, lenC):
      # when classified all bamboos
      if (idx == BAMB_NUM):
          # exists a zero length bamboo
          if (lenA <= 0 or lenB <= 0 or lenC <= 0):
              return sys.maxsize
          return abs(lenA - BAMB_A) + abs(lenB - BAMB_B) + abs(lenc - BAMB_C)
      
      # don't use idx-th bamboo
      mp = calcMP(idx+1, lenA, lenB, lenC)
  
      # use idx-th bamboo
      mp = min(mp, calcMP(idx + 1, lenA + BAMB_LIST[idx], lenB, lenC) + (BAMB_A > 0 ? 10 : 0))
      mp = min(mp, calcMP(idx + 1, lenA, lenB + BAMB_LIST[idx], lenC) + (BAMB_B > 0 ? 10 : 0))
      mp = min(mp, calcMP(idx + 1, lenA, lenB, lenC + BAMB_LIST[idx]) + (BAMB_C > 0 ? 10 : 0))
  
      return mp
  
  if __name__ == "__main__":
      """
      http://drken1215.hatenablog.com/entry/2019/02/24/224100
      """
      # requested bamboo lengths
      bamb_num, bambA, bambB, bambC = map(lambda x: int(x), input().split())
      # available bamboo lengths
      bamb_list = []
      for bamb in range(bamb_num):
          bamb_list.append(int(input()))
  
      mp = calcMP(0, 0, 0, 0)
      print(mp)
problem_description: Statement
  
  You are given a string S as input. This represents a valid date in the year
  2019 in the `yyyy/mm/dd` format. (For example, April 30, 2019 is represented
  as `2019/04/30`.)
  
  Write a program that prints `Heisei` if the date represented by S is not later
  than April 30, 2019, and prints `TBD` otherwise.
samples: [{"input": "2019/04/30", "output": "Heisei\n    \n\n* * *"}, {"input": "2019/11/01", "output": "TBD"}]