[Solved]-Question 4 2 Points Suppose Given Two Sets B Containing N Positive Integers Choose Reorder Q37297902
Questions about Introduction to Algorithms:
Greedy Algorithms.

Question 4 (2 points) Suppose you are given two sets A and B, each containing n positive integers. You can choose to reorder each set however you like. After reordering, let a be the ith element in A and bi be the ith element in B. You will receive a payoff of ET1 aib a) If you reorder A and B into monotonically decreasing order, consider any indices i and j such that i < j, which of the two combinations has higher value: aibi + ajb, or aibj + b,aj? Prove your answer. Based on this, describe the optimal way of reordering that maximizes your payoff. b) If you receive payoff of 1 a’, what is the way of reordering to maximize the payoff? Prove your answer in a similar way to a) Briefly describe how your methods above can be viewed as greedy algorithms. c) Show transcribed image text Question 4 (2 points) Suppose you are given two sets A and B, each containing n positive integers. You can choose to reorder each set however you like. After reordering, let a be the ith element in A and bi be the ith element in B. You will receive a payoff of ET1 aib a) If you reorder A and B into monotonically decreasing order, consider any indices i and j such that i
Expert Answer
Answer to Question 4 (2 points) Suppose you are given two sets A and B, each containing n positive integers. You can choose to reo… . . .
OR

