Company: Opentext_13nov
Difficulty: medium
Account Balance After Donations Problem Description An NGO is developing an app through which people can donate money to help families in need. Each family has a unique ID. There are N accounts with unique account IDs from 0 to N-1. The NGO receives M donations from individuals and entities. They wish to distribute the donations to the accounts in such a way that the account with the lowest balance amount will receive the donation first. If two or more accounts have the same low balance amount in their accounts, then the account with the smaller ID will take precedence. The app will keep track of the total balance in the accounts. The NGO wishes to find the account balance after all the donations have been distributed. Write an algorithm to get the account balance in the application after all the donations have been distributed. Input The first line of the input consists of an integer numAccount, representing the number of families (N). The second line consists of N space-separated int