J.P. Morgan interview question

Given an array, return the combination of elements that yields the max sum.

Interview Answer

Anonymous

6 Jun 2023

Add all the positive elements in the array.