Company: Google big code_21march
Difficulty: medium
Emma is attending a food festival where there are N varieties of specialty snacks available in unlimited quantities. Each snack variety provides a certain amount of satisfaction points, has a specific calorie count, and costs a particular amount. Emma wants to achieve at least X satisfaction points from her snack selections, but she needs to limit her calorie intake to no more than Y calories. She is trying to determine the minimum amount of money required to reach at least X satisfaction points without exceeding Y calories. It's guaranteed that it's possible for Emma to achieve at least X satisfaction points while staying within the Y calorie limit. Function description Complete the solve() function. The function takes the following 6 parameters and returns an integer denoting the answer to the question: N: Represents the number of elements in the array A: Represents the satisfaction points array of N elements B: Represents the calorie count array of N elements C: Represents the cost