parameters: (self, bloomDay, m, k)
return_statement: return left
docstring: :type bloomDay: List[int]
          :type m: int
          :type k: int
          :rtype: int
docstring_summary: :type bloomDay: List[int]
          :type m: int
          :type k: int
          :rtype: int
docstring_tokens: : type bloomDay : List [ int ] : type m : int : type k : int : rtype : int
function: def minDays(self, bloomDay, m, k):
          """
          :type bloomDay: List[int]
          :type m: int
          :type k: int
          :rtype: int
          """
          def check(bloomDay, m, k, x):
              result = count = 0
              for d in bloomDay:
                  count = count+1 if d <= x else 0
                  if count == k:
                      count = 0
                      result += 1
                      if result == m:
                          break
              return result >= m
  
          if m*k > len(bloomDay):
              return -1
          left, right = 1, max(bloomDay)
          while left <= right:
              mid = left + (right-left)//2
              if check(bloomDay, m, k, mid):
                  right = mid-1
              else:
                  left = mid+1
          return left
function_tokens: def minDays ( self , bloomDay , m , k ) : def check ( bloomDay , m , k , x ) : result = count = 0 for d in bloomDay : count = count + 1 if d <= x else 0 if count == k : count = 0 result += 1 if result == m : break return result >= m if m * k > len ( bloomDay ) : return - 1 left , right = 1 , max ( bloomDay ) while left <= right : mid = left + ( right - left ) // 2 if check ( bloomDay , m , k , mid ) : right = mid - 1 else : left = mid + 1 return left