Q5 Brute Froce Given a set of people design a burteforce algorithm that finds the two people most compatible. Assume that there exists a function called compatibility(person1,person2) and it in O(1) time returns the compatibility between the person and person2. Analyze your algorithm.

icon
Related questions
Question

Please solve the following computer science problem: 

 

Q5 Brute Froce
Given a set of people design a burteforce algorithm that finds the two people most compatible.
Assume that there exists a function called compatibility(person1,person2) and it in O(1) time
returns the compatibility between the person and person2.
Analyze your algorithm.
Transcribed Image Text:Q5 Brute Froce Given a set of people design a burteforce algorithm that finds the two people most compatible. Assume that there exists a function called compatibility(person1,person2) and it in O(1) time returns the compatibility between the person and person2. Analyze your algorithm.
Expert Solution
steps

Step by step

Solved in 2 steps

Blurred answer