Question
Consider a sequence of n real numbers (assume n is even). Partition the n numbers into n/2 pairs (each of the n numbers appears in
Consider a sequence of n real numbers (assume n is even). Partition the n numbers into n/2 pairs (each of the n numbers appears in exactly one of the n/2 pairs) in the following way. For each pair in the partition, compute the sum of its numbers. Denote by the n/2 sums. The goal is to find the partition that minimizes the maximum sum. (a) Describe concisely in English the idea of a brute-force algorithm for solving this problem, and provide, using big-O notation, the worst-case running time of your algorithm. (b) Establish a mathematical result that will allow you to design a worst-case polynomial-time algorithm for the problem, and prove the result. (c) Describe the polynomial-time algorithm and provide, using big-O notation, its worst-case running time
X1, 12, ...InStep 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