Computers and Technology

For each problem below, do not write pseudocode. Explain with words why your algorithm is correct and analyse its running time. Problem 1 (rating restaurants) You are writing a blog about restaurants in various cities. You have a list of the 16 top restaurants in La Habana but you don't trust the reviewer. You have a friend in there who is willing to help and all you want to do is provide the best of these 16 restaurants and the worst of these 16 restaurants. So you ask your friend to compare restaurants and give you her opinion on the best and the worst. (a) Briefly explain how your friend can help you doing 30 comparisons.
(b) Design an algorithm your friend can apply to help you if the list has n 2k many restaurants.
Your input is a list of n restaurants and your friend can compare any two in O(1) time. You want to output the best and the worst. Explain why your algorithm is correct and state and analyse its running time. Fastest (and correct) solutions worth more credit.

answer
Answers: 1

Other questions on the subject: Computers and Technology

image
Computers and Technology, 23.06.2019 00:30, amy20021
Write the html code to make a link out of the text “all about puppies”. it should link to a pdf called “puppies. pdf” inside the “documents” folder. the pdf should open in a new window.
Answers: 2
image
Computers and Technology, 23.06.2019 01:20, sosick90501
Write a function balancechemical to balance chemical reactions by solving a linear set of equations. the inputs arguments are: reagents: symbols of reagents in string row array products: symbols of products in string row array elements: elements in the reaction in string row array elcmpreag: elemental composition of reactants in two dimensional numeric array elcmpprdcts: elemental composition of prducts in two dimensional numeric array hint: the first part of the problem is setting up the set of linear equations that should be solve. the second part of the problem is to find the integers from the solution. one way to do this is to mulitiply the rational basis for the nullspace by increasing larger integers until both the left-and right-side integers exist. for example, for the reaction that involves reacting with to produce and : reagents=["ch4", "o2"]; products =["co2", "h2o"]; elements =["c","h", "o"] elcmpreag=[1,4,0;
Answers: 3
image
Computers and Technology, 23.06.2019 03:30, bellsbella34
Ihave a singular monitor that is a tv for my computer. recently, i took apart my computer and put it back together. when i put in the hdmi cord and booted the computer to see if it worked, the computer turned on fine but the screen was blue with "hdmi no signal." i've tried everything that doesn't require buying spare parts, any answer is appreciated!
Answers: 1
image
Computers and Technology, 23.06.2019 04:00, china236
In a word processing program, such as microsoft word, which feature to you choose the desired picture enhancement?
Answers: 2
Do you know the correct answer?
For each problem below, do not write pseudocode. Explain with words why your algorithm is correct an...

Questions in other subjects: