The first line of input contains two integers 'M', and 'N', where 'M' denotes the number of rows and 'N' denotes the number of fans waiting in the line to get a ticket.
The second line contains 'M' single space-separated integers where 'VACANT_SEATS[i]' denotes the number of seats initially empty in the ith row.
For each output, print a single integer denoting the maximum pounds the club will earn.
You do not need to print anything, it has already been taken care of. Just implement the given function.
1 <= 'M' <= 5 * 10^5
1 <= 'N' <= 10^9
1 <= 'VACANT_SEATS[i]' <=10^9
Time Limit: 1 sec
Longest Subarray With Zero Sum
Merge Two Sorted Arrays Without Extra Space
Ninja And The Strictly Increasing Array
Negative To The End
Sort 0s, 1s, 2s