Sir has not covered merge function in array session and here he directly started with merge sort algorithm so please explain merge function first.
Merge function in C++
bhaiya please debug this code
hi @ritikbunty2511_729d0258992e0982 the function of merge is just to merge the arrays chunk wise in sorted manner. and temp ki size badi kr do like int temp[1000000];
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.
Bhaiya code to ab sahi se run kar raha hai but array ka size bada q lena pad raha hai , jabki kam size yeni (e-s+1) ka he jarurat hai
Hi @ritikbunty2511_729d0258992e0982 wo size required hai but indexes alag ho sakte suppose the merge is on Intex 11 to 15 but u r making array of size 5 so it will not work
Okay, but jab mai mid ko bhi pass kar raha hu as an argument tab same size yeni(e-s+1) pe he sahi output aa raha hai
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.