retagged by
1,484 views

1 Answer

0 votes
0 votes
Merge Sort is called $2*n-1$ times, merge function $n-1$ times.

As it says about number of calls required for partitioning the array not sorting, so we calculate only number of times merge sort is called.

so $x = 20*2-1 = 39$

$y = 4*39 +6 = 162$

Related questions

0 votes
0 votes
0 answers
2
Nandkishor3939 asked Jan 21, 2019
679 views
What is the extra memory needed for merge sort:1] In case of Iterative merge sort.(DS:Array)2]In case of Recursive merge sort.(DS:Array)3] In case of Iterative merge sort...
0 votes
0 votes
0 answers
3
Vikas123 asked Jan 8, 2019
994 views
Can anyone help me to understand this problem….??
0 votes
0 votes
1 answer
4
Abhisek Tiwari 4 asked Nov 24, 2018
623 views
no of comparisons in merge sort max?how many max no swaps??[if inplace algo]