Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Question 10 (a) Name two of the algorithmic strategies that we have discussed and briefly describe them. [4 marks] (b) You are trying to find
Question 10 (a) Name two of the algorithmic strategies that we have discussed and briefly describe them. [4 marks] (b) You are trying to find a book in the Barr Smith Library. Outline two different algorithms that you could use, with a discussion of your as- sumptions, overall efficiency and the worse case scenario. You may use approximations to give a sense of scale but your assumptions should be sensible. 8 marks] (c) StabSearch is an algorithm where you take all of the items in your search set, throw them into the air, wait until they land and then throw a knife at them. You check the object stabbed with the knife and you stop searching if it was what you were looking for. If you have not yet found it, you remove the knife, take all of the objects and throw them back up into the air. You repeat this until you find the object. How can you alter this algorithm to give it the same worst case com- putational complexity as exhaustive search? 2 marks] Question 10 (a) Name two of the algorithmic strategies that we have discussed and briefly describe them. [4 marks] (b) You are trying to find a book in the Barr Smith Library. Outline two different algorithms that you could use, with a discussion of your as- sumptions, overall efficiency and the worse case scenario. You may use approximations to give a sense of scale but your assumptions should be sensible. 8 marks] (c) StabSearch is an algorithm where you take all of the items in your search set, throw them into the air, wait until they land and then throw a knife at them. You check the object stabbed with the knife and you stop searching if it was what you were looking for. If you have not yet found it, you remove the knife, take all of the objects and throw them back up into the air. You repeat this until you find the object. How can you alter this algorithm to give it the same worst case com- putational complexity as exhaustive search? 2 marks]
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started