언어, 알고리즘 공부/백준2020. 3. 22. 13:06[백준 알고리즘] 1920번 수 찾기 (Python)
def binary_search(target, start, end, datalist): if start > end: return False mid = (start+end)//2 if datalist[mid] == target: return True elif datalist[mid] > target: return binary_search(target, start, mid-1, datalist) else: return binary_search(target, mid+1, end, datalist) N = int(input()) A = list(map(int, input().split())) M = int(input()) M_list = list(map(int, input().split())) A.sort() ..