func_code: def bsearch(a, q):
      A = False
      found = A
      newSet = q
      while found != True or newSet > 0:
          midpoint = int(len(newSet) / 2)
          if a < newSet[midpoint]:
              found = A
              newSet = newSet[:midpoint]
          elif a > newSet[midpoint]:
              found = A
              newSet = newSet[midpoint:]
          elif a == newSet[midpoint]:
              found = True
      return found