What will the number of comparisions needed in worst case my merge - ProProfs Discuss
Topics
Products
Follow Us:

What will the number of comparisions needed in worst case my merge sort algorithm be? Consider two sorted lists of size L1, L2.



A. L1,L2
B. Max(L1,L2)
C. Min(L1,L2)
D. L1+L2-1

This question is part of Online Test on Algorithms And Data Structures - ICTTRENDS-DSA-01
Asked by Shkhanal, Last updated: Jul 31, 2020

+ Answer
Request

2 Answers

Matz Lewis Clark

Traveler and writer by profession.

Matz Lewis Clark, College student, Graduation, Orlando

Answered Apr 19, 2019

D is the answer to this question. Are you familiar with what an algorithm is? This is the process by which there is a specification on how the programs and problems can be solved. There are different algorithms that can be performed by human beings but it is more likely that the algorithms will be performed by different machines.

Aside from calculation, algorithms are also known to be effective in processing different types of data, automated reasoning, and a lot of other tasks that are available. There are times when the algorithm will be in charge of making some processes clearer. Some machines are not meant to solve vague instructions that may come from people.

 

shkhanal

Shkhanal

Answered Jul 05, 2018

L1+l2-1
 

Search for Google images
Select a recommended image
Upload from your computer
Search for Google images
Select a recommended image
Upload from your computer
Search for Google images
Select a recommended image
Upload from your computer

Email Sent
We have sent an email to your address "" with instructions to reset your password.