이분탐색1 [python] 백준 1920번 수 찾기 https://www.acmicpc.net/problem/1920 1920번: 수 찾기 첫째 줄에 자연수 N(1 ≤ N ≤ 100,000)이 주어진다. 다음 줄에는 N개의 정수 A[1], A[2], …, A[N]이 주어진다. 다음 줄에는 M(1 ≤ M ≤ 100,000)이 주어진다. 다음 줄에는 M개의 수들이 주어지는데, 이 수들 www.acmicpc.net def bin_search(a,key): start=0 end=len(a)-1 while starta[mid]: start= mid+1 else: end=mid-1 if start > end: return 0 n=int(input()) N=list(map(int,input().split())) N.sort() m=int(input()) M=list(.. 2021. 5. 5. 이전 1 다음