Trying Problem Using Return Function Loop Don T Know Wrong Would Like Someone Else Give An Q30017425

Iam trying to do this problem using a return function and a do whileloop. I don’t know what I am doing wrong but I would like someoneelse to give an answer so I can compare. Please write in c++.
Write a program with function which uses a static variable to keep track of the current balance of a bank account. Do not allow an overdraft! A typical run would be: CWindowslsystem321cmd.exe nter anount of transaction, positive for deposit, negative For withdraual 145.00 urrent balance145.00 Do you have more transactions? or N nter anount of transaction positive fordeposit, negative for withdraual 5.00 urrent balance170.00 Do you have more transactions? Y or N nter anount of transaction, positive For deposit. negative for withdrawal 30.00 urrent balance140.00 o you have more transactions? Y or N nter anount of transaction, positive for deposit, negative for withdrawal 150.8 Inpernissible vithdrawal. insufficient funds nter anount of transaction, positive For deposit, negative for withdraual 15.00 urrent balance 125.00 Do you have nore transactions? Y or N Final balance 125.00 ress any key to continue nter anount of transaction,positive for deposit. negative for withdraual 145.00 urrent balance145.00 Do you have nore transactions? Y or N nter anount of transaction, positive for deposit. negative for withdraual 5.00 urrent balance170.00 Do you have nore transactions? or N nter anount of transaction, positive for deposit. negative for withdraval 30.00 urrent balance140.08 Do you have nore transactions? Y or N Enter anount of transaction positive for deposit, negative for withdraval 150.80 Inpernissible withdrawal. insufficient funds nter anount of transaction. positive for deposit, negative for withdraual 15.00 urrent balance125.00 Do you have nore transactions? or N Final balance 125.00 Press any key to continueThank you.Write a program with function which uses a static variable to keep track of the current balance of a bank account. Do not allow an overdraft! A typical run would be: CWindowslsystem321cmd.exe nter anount of transaction, positive for deposit, negative For withdraual 145.00 urrent balance145.00 Do you have more transactions? or N nter anount of transaction positive fordeposit, negative for withdraual 5.00 urrent balance170.00 Do you have more transactions? Y or N nter anount of transaction, positive For deposit. negative for withdrawal 30.00 urrent balance140.00 o you have more transactions? Y or N nter anount of transaction, positive for deposit, negative for withdrawal 150.8 Inpernissible vithdrawal. insufficient funds nter anount of transaction, positive For deposit, negative for withdraual 15.00 urrent balance 125.00 Do you have nore transactions? Y or N Final balance 125.00 ress any key to continue nter anount of transaction,positive for deposit. negative for withdraual 145.00 urrent balance145.00 Do you have nore transactions? Y or N nter anount of transaction, positive for deposit. negative for withdraual 5.00 urrent balance170.00 Do you have nore transactions? or N nter anount of transaction, positive for deposit. negative for withdraval 30.00 urrent balance140.08 Do you have nore transactions? Y or N Enter anount of transaction positive for deposit, negative for withdraval 150.80 Inpernissible withdrawal. insufficient funds nter anount of transaction. positive for deposit, negative for withdraual 15.00 urrent balance125.00 Do you have nore transactions? or N Final balance 125.00 Press any key to continue Show transcribed image text Write a program with function which uses a static variable to keep track of the current balance of a bank account. Do not allow an overdraft! A typical run would be: CWindowslsystem321cmd.exe nter anount of transaction, positive for deposit, negative For withdraual 145.00 urrent balance145.00 Do you have more transactions? or N nter anount of transaction positive fordeposit, negative for withdraual 5.00 urrent balance170.00 Do you have more transactions? Y or N nter anount of transaction, positive For deposit. negative for withdrawal 30.00 urrent balance140.00 o you have more transactions? Y or N nter anount of transaction, positive for deposit, negative for withdrawal 150.8 Inpernissible vithdrawal. insufficient funds nter anount of transaction, positive For deposit, negative for withdraual 15.00 urrent balance 125.00 Do you have nore transactions? Y or N Final balance 125.00 ress any key to continue nter anount of transaction,positive for deposit. negative for withdraual 145.00 urrent balance145.00 Do you have nore transactions? Y or N nter anount of transaction, positive for deposit. negative for withdraual 5.00 urrent balance170.00 Do you have nore transactions? or N nter anount of transaction, positive for deposit. negative for withdraval 30.00 urrent balance140.08 Do you have nore transactions? Y or N Enter anount of transaction positive for deposit, negative for withdraval 150.80 Inpernissible withdrawal. insufficient funds nter anount of transaction. positive for deposit, negative for withdraual 15.00 urrent balance125.00 Do you have nore transactions? or N Final balance 125.00 Press any key to continue

0 replies

Leave a Reply

Want to join the discussion?
Feel free to contribute!

Leave a Reply

Your email address will not be published. Required fields are marked *