Question: Problem 1 (20 points) a) (10 pts) Consider two algorithms A and B with running times TA(n)=2000n and TB(n)=n2/1000, respectively. Algorithm A solves instances of

 Problem 1 (20 points) a) (10 pts) Consider two algorithms A

Problem 1 (20 points) a) (10 pts) Consider two algorithms A and B with running times TA(n)=2000n and TB(n)=n2/1000, respectively. Algorithm A solves instances of size n=500 in 1 millisecond. At the same time, algorithm B manages to solve instances of size n=50000. Which one should be used to solve instances of size n=1000000 ? b) (10 pts) How large of a problem can be solved in 1 hour by each algorithm? Show your work for full credit

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!