retagged by
681 views
0 votes
0 votes

We write a new algorithm by considering the fact that number of comparisons required by Selection Sort can be reduced by considering elements in pairs and finding the minimum and maximum element at the same time.

What will be the time complexity of the new algorithm for comparisons of Selection Sort?

  1.    $O/2$
  2.    $O(n)/4$
  3.    $O(n)$
  4.    $O$$(\log n)$
retagged by

1 Answer

Best answer
1 votes
1 votes
The new algorithm will only reduce the number of comparisons but will not reduce the complexity.
selected by
Answer:

Related questions

460
views
3 answers
0 votes
Bikram asked Feb 9, 2017
460 views
Partitioning and Merging are the two main parts of $Quick Sort$. Which of the following is TRUE? Partitioning is the key step while Merging is trivial. Partitioning...
226
views
1 answers
1 votes
Bikram asked Feb 9, 2017
226 views
Bubble sort is used to sort the following sequence of numbers: $7 5 3 1 2 9$.What will the sequence be after the 2$^{nd}$ iteration?$1$ $2$ $3$ $5$ $7$ $9$$3$ $1$ $2$ $5$...
857
views
2 answers
6 votes
Bikram asked Jan 24, 2017
857 views
A Multinational software vendor needs to choose two sorting algorithm implementations $S1$ and $S2$ to built a software for it's offshore clients.$S1$ will be used in sit...
940
views
1 answers
2 votes
Bikram asked Feb 9, 2017
940 views
Consider the following set of messages with their frequencies: $$\begin{array}{|c|c|c|} \hline \textbf{Message} & \textbf{Frequency} \\ \hline A & 50\: \text{million} \...