ROSALIND|Binary Search (BINS)
給定長度為 n 的嚴格遞增數列,求指定數字在此數列的位置。
Given: Two positive integers $n \leq 10^5$ and $m \leq 10^5$, a sorted array $A[1..n]$ of integers from $-10^5$ to $10^5$, and a list of $m$ integers $-10^5 \leq k_1, k_2, \ldots, k_m \leq 10^5$.
Return: For each $k_i$, output an index $1 \leq j \leq n$ such that $A[j] = k_i$, or “$-1$” if there is no such index.