Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Exercise 6.4. Timing Selection Sort Smallest number of points that requires three seconds (N points): Give times for three runs with N points: Average time:

image text in transcribedimage text in transcribedimage text in transcribedimage text in transcribed

Exercise 6.4. Timing Selection Sort Smallest number of points that requires three seconds (N points): Give times for three runs with N points: Average time: Estimate of time for 2N points: Give times for two runs with 2N points: Do you think the theoretical estimate was fairly accurate or not? Exercise 6.5. Timing Insertion Sort Smallest number of points that requires three seconds (N points): Give times for three runs with N points: Average time: Estimate of time for 2N points: Give times for two runs with 2N points: Do you think the theoretical estimate was fairly accurate or not? How well would doubling the time for N points work as a prediction for 2N points? Exercise 6.6. Timing Quick Sort Smallest number of points that requires three seconds (N points): Give times for three runs with N points: Average time: Estimate of time for 2N points: Give times for two runs with 2N points: Estimate of time for 4N points: Give times for two runs with 4N points: Do you think the theoretical estimate was fairly accurate or not? Exercise 6.7. A mystery sort which algorithm did you choose? Merge sort or Heap sort) Smallest number of points that requires three seconds (N points): Give times for three runs with N points: Average time: Estimate of time for 2N points assuming algorithm is (n): Estimate of time for 2N points assuming algorithm is on Lgn): Give times for two runs with 2N points: What do you believe is the most likely classification for this algorithm? Exercise 6.4. Timing Selection Sort Smallest number of points that requires three seconds (N points): Give times for three runs with N points: Average time: Estimate of time for 2N points: Give times for two runs with 2N points: Do you think the theoretical estimate was fairly accurate or not? Exercise 6.5. Timing Insertion Sort Smallest number of points that requires three seconds (N points): Give times for three runs with N points: Average time: Estimate of time for 2N points: Give times for two runs with 2N points: Do you think the theoretical estimate was fairly accurate or not? How well would doubling the time for N points work as a prediction for 2N points? Exercise 6.6. Timing Quick Sort Smallest number of points that requires three seconds (N points): Give times for three runs with N points: Average time: Estimate of time for 2N points: Give times for two runs with 2N points: Estimate of time for 4N points: Give times for two runs with 4N points: Do you think the theoretical estimate was fairly accurate or not? Exercise 6.7. A mystery sort which algorithm did you choose? Merge sort or Heap sort) Smallest number of points that requires three seconds (N points): Give times for three runs with N points: Average time: Estimate of time for 2N points assuming algorithm is (n): Estimate of time for 2N points assuming algorithm is on Lgn): Give times for two runs with 2N points: What do you believe is the most likely classification for this algorithm

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Graph Databases In Action

Authors: Dave Bechberger, Josh Perryman

1st Edition

1617296376, 978-1617296376

More Books

Students also viewed these Databases questions