• 2022-06-03
    快速排序的时间复杂度________
    A: 为O(n log n)
    B: 为O(n^2)
    C: 介于O(n log n)与O(n^2)之间,偏向于O(n log n)
    D: 介于O(n log n)与O(n^2)之间,偏向于O(n^2)
  • C

    内容

    • 0

      An algorithm has running time $T(n)$, which satisfies $T(n) = 4T(n/4) + O(n)$.So, its running time is _____. A: $O(n\log n)$ B: $O(n)$ C: $O(n^2)$ D: $O(n^2\log n)$

    • 1

      快速排序算法的平均时间复杂度是() A: O(1) B: O(n) C: O(n*log₂n) D: O(n²)

    • 2

      If an algorithm has running time $T(n)= O(n\log n)$, then $T(n)$ may most likely satisfy that _____. A: $T(n) = 4T(n/4) + O(n^2)$ B: $T(n) = 4T(n/4) + O(n) $ C: $T(n) = 3T(n/2)+O(n) $ D: $T(n) = 2T(n/2) + O(\log n)$

    • 3

      下列程序段的时间复杂度为[img=310x120]17e4401665513d0.png[/img] A: O(log n) B: O(n) C: O(1) D: O(n log n)

    • 4

      冒泡排序的时间复杂度是() A: O(n 2 ) B: O(nlog 2n) C: O(n) D: O(log 2n)