[Solved] CH08-320201-Homework 5 Quicksort, Randomized Quicksort and Decision Trees

$25

File Name: CH08-320201-Homework_5_Quicksort,_Randomized_Quicksort_and_Decision_Trees.zip
File Size: 687.66 KB

SKU: [Solved] CH08-320201-Homework 5 Quicksort, Randomized Quicksort and Decision Trees Category: Tag:
5/5 - (1 vote)

Problem 1: Quicksort

  • Implement a modified version of the Quicksort algorithm, where the sequence is always split into three subsequences by simultaneously using the first two elements as pivots.
  • Derive the best-case and worst-case running time for the modified Quicksort in (a).
  • Implement a modified version of the Randomized Quicksort algorithm, where the sequence is always split into three subsequences by simultaneously using two random elements as pivots.

Problem 2: Randomized Quicksort

To formally complete the proof of the expected time complexity E[T(n)] for the Randomized Quicksort algorithm when applied to an input sequence of length n, provide the following steps:

  • Show by induction that
  • Show by induction that

E[T(n)] cnlgn

for a constant c> 0.

Problem 3: Decision Trees.

Show that lgn! = (nlgn) without using Stirlings formula.

Reviews

There are no reviews yet.

Only logged in customers who have purchased this product may leave a review.

Shopping Cart
[Solved] CH08-320201-Homework 5 Quicksort, Randomized Quicksort and Decision Trees
$25