Loading Company...
This is a verified interview question from Amazon-ml-summer-school. Candidates reporting seeing this problem in recent Online Assessments (OAs) and onsite rounds. Mastering "Minimum Cost to Select a Subarray" covers key patterns like Other.
"Given two arrays A and B, and an integer K, find the minimum cost to select a subarray from A that meets the energy requirement of at least K. The cost of selecting a subarray is determined by summing up the corresponding values from B for the same indices."
Join thousands of developers practicing for Amazon-ml-summer-school.