|
|||
Save SetuRahaduzzaman Setu, Roll 12 of 13th batch, CSE, University of Dhaka is tremendously ill. He has been suffering from multidrug-resistant tuberculosis for a long time. Now, his left lung is damaged and beyond repair. No medicine is working on his body to ease his pain. It is urgent to operate on his left lung so that the disease doesn't spread to his right lung. It can either be removed through surgery or transplanted. He comes from a modest family, and it is difficult and impossible for them to bare his medical expenses anymore. Because of the money needed to transplant (12 million BDT), it is his family's decision to go with the surgery (3 million BDT). We must help them financially by raising money. But we must not be confined with that amount only to do the surgery. We must go for the transplant. Our target will be to collect as much as possible to help our friend. In this problem, you have to build a software that can calculate the donations. Initially, the total amount of money is 0, and each time, two types of operations will be there:
Input SpecificationThe first line of the input will contain T (1 ≤ T ≤ 100), denoting the number of operations. Then there will be T lines, each containing two types of operations as given above. You may assume that the input follows the restrictions described above. Output SpecificationFor each “report” operation, print the total amount of money in the account on a line by itself. Sample Input
Output for Sample Input
|
|||
University of Debrecen; Faculty of Informatics; v. 09/30/2024 |