Home:ALL Converter>what is the worst and best case run time for insertion sort and merge sort?

what is the worst and best case run time for insertion sort and merge sort?

Ask Time:2019-11-15T06:59:02         Author:TheCodeLearner

Json Formatter

Which of these are correct? worst and best case run time for insertion and merge sort?

insertion sort (best case): big O(n) or theta (n) (worst case):big O(n^2) or theta (n^2)?

merge sort (best case) : big O(n log n) or theta (n log n) (worst case) : big O (n log n) or theta (nlog n)?

Author:TheCodeLearner,eproduced under the CC 4.0 BY-SA copyright license with a link to the original source and this disclaimer.
Link to original article:https://stackoverflow.com/questions/58867807/what-is-the-worst-and-best-case-run-time-for-insertion-sort-and-merge-sort
yy