Question: Please choose the best suitable algorithm from the list to solve each of the following problems. Insertion sort algorithm Selection sort algorithm Merge-Sort algorithm Heap-Sort
Please choose the best suitable algorithm from the list to solve each of the following problems.
Insertion sort algorithm
Selection sort algorithm
Merge-Sort algorithm
Heap-Sort algorithm
Quick-Sort algorithm
Counting-Sort algorithm
Radix-Sort algorithm
Bucket-Sort algorithm
None of the Above
(5) Suppose you are running a library catalog. You know that the books are almost in sorted ascending order by title, except for few books which are in the wrong place. To sort the catalog, what sorting algorithm would work best for this case?
(5) Suppose you are working on an ATM device that has only 8KB (8,192 bytes) of free memory, and you want to sort the 2,000,000-transaction history by the amount of money discarding the original order of transactions. To sort the transactions, what sorting algorithm would work best for this case?
(5) Suppose you want to determine which of your Facebook friends are early adopters, and you decide to sort them by their Facebook account ids, which are 64-bit integers. (Recall that you are super popular, so you have very many Facebook friends.) To sort the account ids, what sorting algorithm would work best for this case?
(5) Suppose you are working on a legacy system of XYZ Inc. which maintains multiple customer account lists. The lists are already sorted in ascending order by account numbers and all account numbers are unique. Since maintaining multiple lists can be error-prone and slowed down the operation, you decide to merge all lists into one sorted list by account numbers. What algorithm would work best for this case?
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
