Login
Register
@
Dark Mode
Profile
Edit my Profile
Messages
My favorites
Register
Activity
Q&A
Questions
Unanswered
Tags
Subjects
Users
Ask
Previous Years
Blogs
New Blog
Exams
Dark Mode
MadeEasy Test Series: Algorithms - Sorting
rahul sharma 5
asked
in
Algorithms
Dec 8, 2017
edited
Mar 7, 2019
by
Aditi Singh
1,037
views
0
votes
0
votes
Which of the following sorting techniques have best time complexity, if complexity is measured in terms of number of comparison?
A Insertion sort
B Selection sort
C Merge sort
D QuickSort
made-easy-test-series
algorithms
sorting
time-complexity
rahul sharma 5
asked
in
Algorithms
Dec 8, 2017
edited
Mar 7, 2019
by
Aditi Singh
by
rahul sharma 5
1.0k
views
answer
comment
Follow
share this
share
1 comment
by
Mohit Kumar 6
commented
Apr 27, 2020
reply
Follow
share this
It depends on lot of factors.
1. Size of input. => Quick sort
2. How well is it sorted. => Insertion sort
3. Can your system allot more space for sorting to function. => Merge sort
i think question is incomplete,
0
0
Please
log in
or
register
to add a comment.
Please
log in
or
register
to answer this question.
2
Answers
0
votes
0
votes
In best case input, insertion sort.
In worst case input, merge sort.
vishalshrm539
answered
Dec 8, 2017
by
vishalshrm539
comment
Follow
share this
2 Comments
by
rahul sharma 5
commented
Dec 8, 2017
reply
Follow
share this
Please give one best answer as per option
0
0
by
vishalshrm539
commented
Dec 9, 2017
reply
Follow
share this
One answer could be merge sort.
1
1
Please
log in
or
register
to add a comment.
0
votes
0
votes
In worst case input merge sort is better.
abhishekmehta4u
answered
Mar 8, 2019
by
abhishekmehta4u
comment
Follow
share this
2 Comments
by
Priyadrasta Raut
commented
Oct 22, 2019
reply
Follow
share this
the question is given to measure time complexity on the basis of no of comparisons not the asymptotic meaning
0
0
by
Satbir
commented
Oct 22, 2019
reply
Follow
share this
Time complexities can be obtained based on number of comparisons.
0
0
Please
log in
or
register
to add a comment.
← Previous
Next →
← Previous in category
Next in category →
Related questions
3
votes
3
votes
4
answers
1
newdreamz a1-z0
asked
in
Algorithms
Jan 21, 2019
1,569
views
MadeEasy Test Series: Algorithms - Sorting
Consider a scenario of modified quick sort, where we have given an input sorted array A[1 .. . n], all elements of array are distinct and n >=3. Pivot is the median of set of 3 elements [First element, middle element, and last element]. What will be worst case time complexity of modified quick sort? a.O($n^{2}$) b.O(nlogn) c.O($n^{2}$logn) d.O(nloglogn)
newdreamz a1-z0
asked
in
Algorithms
Jan 21, 2019
by
newdreamz a1-z0
1.6k
views
algorithms
sorting
quick-sort
made-easy-test-series
0
votes
0
votes
0
answers
2
Abhishek Kumar 38
asked
in
Algorithms
Dec 19, 2018
629
views
MadeEasy Test Series: Algorithms - Sorting
Which of the following sorting algorithm represented by above code?
Abhishek Kumar 38
asked
in
Algorithms
Dec 19, 2018
by
Abhishek Kumar 38
629
views
made-easy-test-series
algorithms
sorting
2
votes
2
votes
1
answer
3
aambazinga
asked
in
Algorithms
Dec 15, 2018
855
views
MadeEasy Test Series: Algorithms - Sorting
An array of size n is known to be sorted except for the 1st k elements and the last k elements, where k is a constant. which of the following algorithm is the best choice for sorting the array A? Quick Sort or Insertion Sort? given answer is the insertion ... k), and it will take O(klogk) in average case and O(k^2) in the worst case. what's wrong in that?
aambazinga
asked
in
Algorithms
Dec 15, 2018
by
aambazinga
855
views
made-easy-test-series
algorithms
sorting
0
votes
0
votes
2
answers
4
Somoshree Datta 5
asked
in
Algorithms
Oct 20, 2018
1,629
views
MadeEasy Test Series: Algorithms - Sorting
Consider the following scenario during insertion sort when the array looks like the following: {25,75,95,125,80,5,10} The number of comparisons that it will further take for the array to be completely sorted are______?
Somoshree Datta 5
asked
in
Algorithms
Oct 20, 2018
by
Somoshree Datta 5
1.6k
views
algorithms
sorting
made-easy-test-series
Subscribe to GATE CSE 2024 Test Series
Subscribe to GO Classes for GATE CSE 2024
Quick search syntax
tags
tag:apple
author
user:martin
title
title:apple
content
content:apple
exclude
-tag:apple
force match
+apple
views
views:100
score
score:10
answers
answers:2
is accepted
isaccepted:true
is closed
isclosed:true
Recent Posts
Post GATE 2024 Guidance [Counseling tips and resources]
GATE CSE 2024 Result Responses
[Project Contest] Pytorch backend support for MLCommons Cpp Inference implementation
Participating in MLCommons Inference v4.0 submission (deadline is February 23 12pm IST)
IIITH PGEE 2024 Test Series by GO Classes
Subjects
All categories
General Aptitude
(3.5k)
Engineering Mathematics
(10.4k)
Digital Logic
(3.6k)
Programming and DS
(6.2k)
Algorithms
(4.8k)
Theory of Computation
(6.9k)
Compiler Design
(2.5k)
Operating System
(5.2k)
Databases
(4.8k)
CO and Architecture
(4.0k)
Computer Networks
(4.9k)
Artificial Intelligence
(79)
Machine Learning
(48)
Data Mining and Warehousing
(25)
Non GATE
(1.4k)
Others
(2.7k)
Admissions
(684)
Exam Queries
(1.6k)
Tier 1 Placement Questions
(17)
Job Queries
(80)
Projects
(11)
Unknown Category
(870)
64.3k
questions
77.9k
answers
244k
comments
80.0k
users
Recent Blog Comments
category ?
Hi @Arjun sir, I have obtained a score of 591 in ...
download here
Can you please tell about IIT-H mtech CSE self...
Please add your admission queries here:...
Twitter
WhatsApp
Facebook
Reddit
LinkedIn
Email
Link Copied!
Copy