Why use left+(right-left)/2 instead of (left+right)/2 in sorting algorithms?
In most sorting algorithms that use the divide and conquer approach, you'd need to find the middle index between two indices. If l is the left index and r is the right index, then our most obvious approach towards finding the half or middle of the tw...
Sep 11, 20212 min read828


