二分查找 python實現

二分查找的python實現,經典的面試題,啥也很少說,直接上代碼python def binary_search(num,list): low = 0 high = len(list) - 1 while(low <= high): middle = (low + high) / 2 if list[middle] > num:
相關文章
相關標籤/搜索