https://www.geeksforgeeks.org/minimize-cash-flow-among-given-set-friends-borrowed-money/