Company: Amazon_22sep
Difficulty: medium
Maximum Performance with Limited Expense Problem Description Amazon is upgrading its network infrastructure and needs to purchase at most two new hardware components to meet the requirement. There are two arrays, expense and performance relating to the n available hardware components. Here expense[i] and performance[i] represent the cost and performance rating of the i th hardware component. Due to procurement limitations, the maximum total expense of the two hardware components is spending_cap . Given two arrays, expense and performance , find the maximum possible performance rating that can be achieved with at most two hardware components whose total expense is less than or equal to spending_cap . Complete the function findMaximumPerformance in the editor below. findMaximumPerformance has the following parameters: int expense[n] : the costs of hardware components int performance[n] : the performance ratings int spending_cap : the maximum expense Returns int : the maximum possible per