Question: Problem 3 [ 2 pts ] . Attached is a program merge.c . It is an implementation of mergesort, where the input is in a

Problem 3[2 pts]. Attached is a program merge.c. It is an implementation of mergesort, where the input is in
a linked list. The output is a linked list is a sorted version of the input, where the output has increasing values.
The function of mergesort is mergesort(). It calls a function merge() which has as input two sorted linked
lists. It merges the two linked list into a single linked list that is sorted. Note that this implementation is the
top-down approach rather than the bottom-up approach discussed in class.
The function merge() is incorrect. Your task is to write a correct version.
Do not change any of the other functions. Do not copy nodes.
Submit your code merge.c in laulima.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!