Describe how one can implement each of the following operations on an array so that the time it takes does not depend on the array’s size n.
a. Delete the ith element of an array (1≤ i ≤ n).
b. Delete the ith element of a sorted array (the remaining array has to stay sorted, of course).
Sorry the answer is not available at the moment…
If you are able to find the answer, please make sure to post it here. So that your Juniors have smile on their lips and feel happy.
Spread the 'tradition of sharing'.