Hello Everyone. I have this take home exam and I am stuck on one of the questions. I'm super desperate, please help. I'm a beginner at C++. This exam is due on Monday (March 18th). I am using Qunicy 2005 since that's what we have been using in class. Below is the program that I need to create. Thanks in advance for your time and consideration:
Write a program that will input the following data:
Last month’s balance (float)
Total deposit for the month (float)
Total amount of checks written for the month (float)
And calculate the following:
New balance – last months balance + total deposits – checks – SERVICE_CHARGE
Requirements for the program to be written:
• The program must prompt the user for the above input from the keyboard. The Service charge must be defined using a symbolic constant and assigned a value of $10.00 (the service charge is a flat $10 per month).
• The program must call a function, passing the input, and calculate the new balance. The new balance must be returned to main().
• Output must occur in a function called Output. This function is to clear the screen and display the following, where xxx.xx refers to the inputted values or calculated values.
Balance last month: xxxx.xx
Total deposits for month: xxxx.xx
Total checks for month: xxxx.xx
Service charge: 10.00
New Balance: $ xxxx.xx
• The program should prompt the user to continue (C) or Quit (Q). Consequently, you must use a loop until the user enters a Q to Quit. If the user enters anything other than a C or Q, signify an error exists in input and give the user a second chance for the input of a C or Q.
• If the New Balance is less than or equal to zero (0), display an error message to the right of the line displaying New Balance: $ xxxx.xx
• Such as: New Balance: $ xxxx.xx – Balance Insufficient
• Output all numeric values to 2 decimal places and be sure to place the $ in the line displaying the New Balance.
• You must turn in a cover sheet, followed by this assignment sheet, a copy of the source code, and a copy of the output.
do
{cout<<"\n";
cout<<"enter last month's balance ";
cin>>lm_bal;
cout<<"enter deposits for month ";
cin>>m_deposit;
cout<<"enter value of cheques written for month ";
cin>>cheque_val;
new_ball=new_bal(lm_bal,m_deposit,cheque_val);
//cout<<"the new balance is $"<<new_ball;
output(lm_bal,m_deposit,cheque_val,new_ball);
char ans;
cout<<"\nto continue enter c (q to quit)";
cin >>ans;
if(ans=='q' || ans== 'Q' )
return 0;
}while(ans!='q');
...don't forget to setprecision(2) above the loop which is defined in the iomanip header file.
I ask specific questions about syntax and logical rules of arrays and nobody helps. But people are lining up to do this guy's homework for him when he hasn't even asked a question... Lovely.
actually army-gal so pretty sure its a girl. second, people did answer them. third, its rude to hijack a post that is in the progress of being answered
Girls/ladies are too much underrepresented in software engineering :-(
Beside the normal girl factor it is proven that females have a better understanding of logic (scientific!) and maths. So I guess they could be of great value if they wouldn't have this strange thinking of what software engineering is.
(But their smart phones they can handle often better than any male)