What are the average number of comparisons required to sort
3 elements?
Answers were Sorted based on User's Feedback
Answer / jaiprakash
n(n-1)/2(bubble sort)
n=3
(3*2)/2=3(n)
ans:n
| Is This Answer Correct ? | 13 Yes | 1 No |
how to use virual function in real time example
List at least 10 sorting methods indicating their average case complexity, worst case complexity and best case complexity.
Which node is more powerful and can handle local information processing or graphics processing?
how do you programme Carrier Sense Multiple Access
What is a good way to implement complex numbers in c?
how to find out the union of two character arrays?
Explain b+ tree?
When should a type cast not be used?
What does calloc stand for?
Determine the code below, tell me exactly how many times is the operation sum++ performed ? for ( i = 0; i < 100; i++ ) for ( j = 100; j > 100 - i; j--) sum++;
struct tag{ auto int x; static int y; };main() { struct tag s; s.x=4; s.y=5; printf(ā%dā,s.x); }
Why c is called a mid level programming language?