public int[] searchRange(int[] A, int target) {
		int res[] = new int[]{-1, -1};
		if(A == null || A.length == 0) return res;
		int pos = binarySearch(A, target);
		if(pos != -1){
			int s, e, m;
			
			s = 0;
			e = pos;
			while(s <= e){
				m = (s + e) / 2;
				if(A[m] == target) e = m - 1;
				else s = m + 1;
			}
			res[0] = s;
			
			s = pos;
			e = A.length - 1;
			while(s <= e){
				m = (s + e) / 2;
				if(A[m] == target) s = m + 1;
				else e = m - 1;
			}
			res[1] = e;
		}
		return res;
	}