import java.util.*; public class BinarySearch { public int getPos(int[] A, int n, int val) { // write code here int left = 0, right = n - 1; boolean exist = false; while(left <= right){ int mid = (left + right) / 2; if(A[mid] == val) exi...