I have a doubt that ,inside a block if the same function is called two or more than two times recursively,then what is the order of execution?
e.g.:in case of mergesort ,for partition if i do like this
mergesort(int a[], int low, int high)
{
int mid;
if(low<high)
{
mid=(low+high)/2;
mergesort(a,low,mid);
mergesort(a,mid+1,high);
merge(a,low,high,mid);
}
then (1) will mergesort(a,low,mid), mergesort(a,mid+1,high) and merge(a,high,mid) be called one by one if condition (low
(2) Or will the call to merge(a,low,mid) will go on recursively and then after merge(a,mid+1,high) is executed recursively and at last merge(a,low,mid) is executed .
I know this is very simple for you skilled guys,but please do a favour to me by answering this.