Get Max Skill Sum
Problem Overview
- Select a contiguous range of employee IDs with equal marketing experts (0) and developers (1), maximizing the total skill sum.
- Input: arrays expertise[n] and skill[n]; Output: a long with the maximum achievable skill; empty team yields 0.
- Employees are numbered 0 to n−1; a contiguous set has no gaps between IDs.
- Real-world context: building a balanced project team at Amazon.
- Amazon interviews coding interview problem: a subarray selection interview question.
Example
Unlock to view complete problem details
and practice with sample input/output
Was this article helpful?
View Test Cases & Run Code requires membership
Input Variables
Execution Result:
