Write a C program to search the element in a list by using the searching method in divide and conquer Technique code example
Example: c++ binary search
int result = -1;
int low = 0;
int high = N-1; // N - # of elements
while (low <= high)
{ mid = (low + high) / 2;
if ( item == vector[mid])
{ result = mid;
break;
}
else if (item > vector[mid] )
{ low = mid + 1; }
else { high = mid - 1; }
}