Join Regular Classroom : Visit ClassroomTech

HackWithInfy 2021: Infosys Coding Contest for 2022 batch

HackWithInfy 2021 Sample Question-C (Minimum Withdrawals) Solution

Problem Statement: There is a unique ATM in Wonderland. Imagine this ATM as an array of numbers. You can withdraw cash only from either ends of the array. Sarah wants to withdraw X amount of cash from the ATM. What are the minimum number of withdrawals Sarah would need to accumulate X amount of cash.

HackWithInfy 2021 Sample Question-C (Minimum Withdrawals) Solution Read More »