1.

Which algorithm is better for sorting between bubble sort and quicksort?(a) bubble sort(b) quick sort(c) both are equally good(d) none of the mentionedThe question was asked by my school principal while I was bunking the class.My question comes from Algorithms in chapter Algorithms of Discrete Mathematics

Answer»

The CORRECT option is (B) quick SORT

Explanation: RUNNING time of quicksort is logarithmic whereas for bubble sort it is quadratic.



Discussion

No Comment Found

Related InterviewSolutions