Hi, I need this C++ Advanced assignment written in Visual Studio by tonight. I am really busy this week and can’t finish it in time. Word docum
Hi, I need this C++ Advanced assignment written in Visual Studio by tonight. I am really busy this week and can't finish it in time. Word document instructions along with the Rubric are attached. Please no plagiarism and include all the files necessary. Thank you!
Criteria Ratings Points
Program Meets the Assignment Requirements
32 to >28.0 pts
Advanced
Program meets all of the assignment requirements.
28 to >21.0 pts
Proficient
Program meets at least 50% but less than 90% of the assignment requirements.
21 to >0.0 pts
Developing
Program meets less than 50% of the assignment requirements.
0 pts
Not Present
32 pts
Program compiles and executes without crashing
10 to >8.0 pts
Advanced
Program compiles and executes without errors.
8 to >6.0 pts
Proficient
Program compiles but encounters an endless loop, “hangs”, or throws an exception.
6 to >0.0 pts
Developing
Program does not compile
0 pts
Not Present
10 pts
Screen shots 3 to >2.0 pts
Advanced
Complete set of screen shots are submitted and are submitted within the Microsoft Word document(s), with the 4 integrity assertions included
2 to >1.0 pts
Proficient
Screen shots are submitted but are either incomplete or are not submitted within the Microsoft Word document(s), or the Microsoft Word document(s) does/do not include the 4 required assertions of integrity.
1 to >0.0 pts
Developing
Screen shots are submitted but are either incomplete or are not submitted within the Microsoft Word document(s), and the Microsoft Word document(s) does/do not include the 4 required assertions of integrity.
0 pts
Not Present
3 pts
C++ Programming Grading Rubric | CSIS112_B01_202230
Criteria Ratings Points
Program Internal Documentation
3 to >2.0 pts
Advanced
Internal comments are sufficient in all files within the program to describe the program’s logic, the meaning of the variables, and the overall purpose of each file, function, and class. The program contains a comment at the top of the driver file that indicates the student’s name, assignment number, and a brief description of the purpose of the program.
2 to >1.0 pts
Proficient
Internal comments are present, but they are not sufficient to describe the logic of the program, the meaning of the variables, or the overall purpose of each file, function, and class; OR The program does not contain a comment at the top of the driver file that indicates the student’s name, assignment number, and a brief description of the purpose of the program.
1 to >0.0 pts
Developing
Comments in the code are minimal and do not contain the student’s name, assignment number, and description of the purpose of the program.
0 pts
Not Present
3 pts
Style of code 12 to >10.0 pts
Advanced
Program is modular. It contains no global variables unless they are constants. Adheres to the principles of minimalization and least privilege: Constants are used where appropriate; variables are declared with the proper level of access (for classes only); only variables that are needed are created; and program uses the correct data structure (array, vector, etc.) for the assignment.
10 to >8.0 pts
Proficient
Program is minimally modular. At most one global variable is declared; at most one variable is declared with the incorrect level of access; at most one variable is declared which should not be used; or the program uses an incorrect data structure for the assignment.
8 to >0.0 pts
Developing
Program is not modular (i.e. everything is contained within main()); multiple global variables are used; more than one variable is declared which should not be present; or the program uses an incorrect data structure for the assignment.
0 pts
Not Present
12 pts
Total Points: 60
C++ Programming Grading Rubric | CSIS112_B01_202230
,
Overview
The purpose of this assignment is to get you back into programming and give you some practice with the new concept of recursion. It also utilizes many of the C++ topics that you should be familiar with from your first course in C++.
Instructions
You are working as a computer programmer for a mortgage company that provides loans to consumers for residential housing. Your task is to create an application to be used by the loan officers of the company when presenting loan options to its customers. The application will be a mortgage calculator that determines a monthly payment for loans and produces an amortization schedule for the life of the loan.
The company offers 10-, 15-, and 30-year fixed loans.
Inputs
The program should initially prompt the user (the loan officer) for the principal of the loan (i.e. the amount that is being borrowed).
It should then ask him or her to enter an annual interest rate for the loan.
The final input should be the number of years that the loan will be outstanding. Because the company only offers three different terms (10-, 15-, and 30-year loans), the program should ensure that no other terms are entered.
Formulas
Payment Calculator
[Adapted from Wittwer, J.W., "Amortization Calculation," From Vertex42.com , Nov 11, 2008.]
The formula to calculate the monthly payment for a fixed interest rate loan is as follows:
where
A = payment Amount per period
P = initial Principal (loan amount)
r = interest rate per period
n = total number of payments or periods
Example: What would the monthly payment be on a 15-year, $100,000 loan with a 4.50% annual interest rate?
P = $100,000 r = 4.50% per year / 12 months = 0.375% (or 0.00375) per period n = 15 years * 12 months = 180 total periods
A = 100,000 * (.00375 * (1 + .00375)180)/((1+.00375)180 – 1)
Using these numbers in the formula above yields a monthly payment of $764.99.
Amortization Schedule
An amortization schedule shows the amount of each monthly payment that is being applied to interest and the amount that is being applied to the principal on a loan.
The Interest portion of the payment is calculated as the rate (r) times the previous balance and should be rounded to the nearest cent. The Principal portion of the payment is calculated as Amount – Interest. The new Balance is calculated by subtracting the Principal from the previous balance. The last payment amount may need to be adjusted (as in the table below) to account for the rounding.
The amortization schedule for the example above is presented here: Note that the first and last three rows are listed here so that you can see the beginning and end of the report. In your program, you must include all of the rows in your output.
Requirements:
To receive credit for this assignment, certain programming features must be implemented in such a way as to demonstrate your knowledge of formulas, functions, input error checking, proper formatting of outputs, and recursion.
1. Start your program by prompting the user to enter a principal amount. The data type of this number should be a double. The amount must be positive and it must also be a numeric value. For example, when prompted to enter a number, if the user enters “abc,” the program will not be able to process the loan appropriately. Likewise, if the user enters -100000, the program will again produce erroneous results. [See below for code that you can use for error checking.]
1. Prompt the user to enter an annual interest rate for the loan as a percent. For example, an annual interest rate of 4.5% should be entered as 4.5. Your program will convert it to .045 for calculations.
If a non-numeric or negative interest rate is entered, prompt the user to re-enter the rate.
1. Prompt the user to enter the term of the loan. Valid terms are 10, 15, and 30 years. Any other entries should be rejected, and the user should be prompted to re-enter an appropriate value.
1. Once the inputs have been entered and validated, your program must calculate the monthly payment for the loan. To receive credit for the loan calculation, you must create a function called CalcPayment that receives the principal, interest rate, and number of years as parameters. The function should return the monthly payment that is calculated.
1. In main(), using the monthly payment that you just calculated, call a function to create an amortization schedule for the loan using these specifications:
4. Create a function called Amortize. It should receive as parameters: currentPeriod, totalPeriods, paymentAmount, monthlyInterestRate, currentBalance.
4. The function MUST be recursive to receive credit for producing the Amortization Schedule.
4. The function should print out the Amortization Schedule to the screen using good formatting (including spelling and grammar where appropriate)
Your program should check for invalid data such as non-numeric and non-positive entries for principal, interest rate, and term. Use proper indentation and style, meaningful identifiers, and appropriate comments.
General notes about error checking
As in all applications, you should design your code to be robust enough to handle anything that a user may enter. In this program, you will prompt the user to enter three numbers: a principal amount, an interest rate, and a number of years (i.e. term). Because users can make mistakes, you need to make sure that they enter numbers for these inputs (as opposed letters or other characters) and that any numbers entered are reasonable . For example, what if a user entered -10000 as the principal amount? Or negative years? What is a negative year anyway? It just doesn’t make sense.
Therefore, you may use the following code to determine if a non-numeric or negative number has been entered:
int num;
cout << "Enter an integer: " << endl;
cin >> num;
while (cin.fail() || num < 0)
{
cout << "You must enter a number, and that number must be positive. Please try again. " << endl;
cin.clear();
cin.ignore(numeric_limits<streamsize>::max(), 'n');
cin >> num;
}
The reason that this code works is due to the behavior of “cin.” Whenever cin tries to read a letter (or any non-numeric character) into a variable that is designed to hold a number, cin enters a fail state, which can produce erroneous results and potentially even cause your program to crash. Therefore, you must trap for non-numeric data whenever the program is expecting a number. One way to trap for this error is to check if “cin” has entered the fail state using the “cin.fail()” function. If it has, then you first have to clear cin out of its fail state using the cin.clear() function. Afterwards, you can issue the “ignore” command which flushes any remaining garbage out of the input stream (aka “cin buffer”). Finally, you can prompt the user to re-enter a correct value. Note that the code above is not especially informative. That is, it produces a single generic error message to the user such that the user may not realize what he did wrong to cause the problem. Therefore, feel free to tweak it as necessary if you want to customize your error messages. One other point of interest is that the code above doesn’t allow the user an opportunity to end the program if he can’t provide an acceptable value. It just continues to loop until an acceptable value is entered. In real life, you would definitely want to allow your user a means of escape. In this assignment, however, continuing to prompt the user for a valid value until one is entered is fine. Later in the course, we’ll learn more sophisticated ways of error checking when we discuss exception handling.
Good luck on this assignment! Have fun with it, and as always, let me know if you have any questions.
To give you an idea of the criteria that will be used for grading, here is a checklist that you might find helpful:
Compiles and Executes without crashing |
Word document contains screen shots and integrity statements |
Appropriate internal documentation |
Style: |
No global variables |
Code is modular |
Recursion is used correctly |
Requirements: |
Inputs |
Prompts user for principal, interest rate, and term with appropriate error checking |
Processing and Outputs |
Correctly calculates payment |
Amortization schedule is correct, formatted appropriately, and produced using a recursive function |
Page 2 of 2
Collepals.com Plagiarism Free Papers
Are you looking for custom essay writing service or even dissertation writing services? Just request for our write my paper service, and we'll match you with the best essay writer in your subject! With an exceptional team of professional academic experts in a wide range of subjects, we can guarantee you an unrivaled quality of custom-written papers.
Get ZERO PLAGIARISM, HUMAN WRITTEN ESSAYS
Why Hire Collepals.com writers to do your paper?
Quality- We are experienced and have access to ample research materials.
We write plagiarism Free Content
Confidential- We never share or sell your personal information to third parties.
Support-Chat with us today! We are always waiting to answer all your questions.