![]() |
Merge-sort issue!
yo yo sup?
so I get this Merge-Sort to be implemented in c,look: **Please notes this:1-The arrays are not sorted and still I got to merge them. 2-Running time must be of order O(n*log(n)) 3-The following code works but I get Runtime Error,so mainly I need your help to find out where the Runtime Error occurs! 4-the two arrays of the same size Code: Code:
int merge_sort(int arr1[], int n)My problem is that this code works for arrays of length of (in the fir 'for' loop)power to 2, what u think? Thanks! |
| All times are GMT +5.5. The time now is 00:55. |