Calculate the monthly cost of a house given selling price

Assignment Help Computer Engineering
Reference no: EM132194675

Question :

Write a C++ program to calculate the monthly cost of a house given the selling price, annual rate of interest, and number of years for the loan. The monthly mortgage payment may be computed using the following formula:

payment = a*i(1+i)n (1 + i)n - 1 where a=amount of loan i=rate of interest per compounding period (annual rate/12) n=number of compounding periods (yrs*12)

Assume that the down payment will be 20% of selling price, yearly tax rate is 1.25% of selling price, utilities will be approximately $300.00 per month, and insurance will be $550.00 per year.

DATA Use preprocessor statements to set the tax rate, cost of insurance, and the cost of utilities. Set the percentage of down payment as a non-global memory constant. Prompt the user for the selling price, the rate of interest, and the number of years for the loan.

CALCULATIONS Use at least four functions in addition to main: a function to input all data, a function which handles all computations including invoking a subfunction to compute the down payment, amount of loan, and mortgage payment, and, finally, one to output the results.

OUTPUT All values input and used in the calculations as well as the monthly payment and total monthly house cost need to be output as follows:

MONTHLY COST OF HOUSE

SELLING PRICE $XXXXXX.XX

DOWN PAYMENT XXXXXX.XX

AMOUNT OF LOAN XXXXXX.XX

INTEREST RATE XX.X%

TAX RATE XX.X%

DURATION OF LOAN (YEARS) XX

MONTHLY PAYMENT MORTGAGE XXXX.XX

UTILITIES XXXX.XX

PROPERTY TAXES XXXX.XX

INSURANCE XXXX.XX

__________ $ XXXXX.XX

Theme issue Functions, sub-functions, pass by reference

3) User defined constants for property tax rate, cost of utilities, and cost of insurance. Use non-global memory constant for percent of down payment.

4) Use exactly one function separate from main for input.

5) Call a calculation function from main which handles all calculations. This function needs to contain a sub-function to calculate the down payment, amount of the loan and monthly mortgage payment.

6) Use exactly one function separate from main for output.

7) Output must be formatted exactly as shown on l write-up with decimal points lined up. Output must go to a file and that file must be uploaded as .txt. No cout object should be left in this function.

8) All functions (other than main() & your signature function) must use prototype style.

Test data (see bankrate.com or use Excel & pmt()to check your answers) Set 1 - $600,000, 5%, 20
Set 2 - $400,000, 4.2%, 30

Reference no: EM132194675

Questions Cloud

How it distinguishes normal and inferior goods : Define income elasticity and how it distinguishes normal and inferior goods.
A program to count words and numbers in a plain text file : Words and numbers can be repeated. You can use any algorithm and data structures that you prefer, as long as the results are correct.
A program to calculates a vehicles gas mileage : The program should ask the user to enter the number of gallons of gas the vehicle can hold and the number of miles it can be driven on a full tank.
Write a description of the selected dataset and project : ITECH1103- Big Data and Analytics - write a brief reflection about this project in terms of challenges, learning and contribution
Calculate the monthly cost of a house given selling price : Write a C++ program to calculate the monthly cost of a house given the selling price, annual rate of interest, and number of years for the loan.
Market for housing as a result : Suppose that consumers begin to believe that the price of housing will be lower next period. What will happen in the market for housing as a result
Write a c program that compiles and runs without errors : Write a C program that compiles and runs without errors or warnings. This program has a bunch of little bit-manipulation functions in it.
Compute how many seconds are in 20 years : Write a C# program to convert one billion seconds (1,000,000,000 seconds) into years, months, days, hours, minutes, and seconds, using visual studio.
Calculate the gross pay of a set of employees : Calculate the gross pay of a set of employees. For each employee the program should prompt the user to enter the clock number.

Reviews

Write a Review

Computer Engineering Questions & Answers

  Differences between security testing and threat modeling

For this assignment identify and explain the key differences between security testing and threat modeling. Please state your answer in a 1-2 page paper.

  Draw the circuit using multiplexers

A two-bit counter C controls the register transfers shown below.

  What privacy issues are involved

You can transfer your health data to another personal health record provider such as Microsoft HealthVault. What privacy issues are involved?

  What problems contribute to read errors on magnetic tapes

What problems contribute to read/write errors on magnetic tapes? Are these problems also present with other magnetic storage media/devices?

  Cnsider that computers are becoming ubiquitous and have

business and cyberethics please respond to the followinga possible view is that business and ethics simply have nothing

  Make up equipment that characterizes trucks

Make up equipment that characterizes trucks. Get the raw data from the ad section of your local newspaper. Instead of using the states in the cars database.

  Elevations of the great lakes in vectors

Pascal allows the use of enumerated types as index types.In the above definitions we stored the areas and elevations.

  Describe briefly the shorthand method of programming

ControlLogix processors use what in place of addresses as found on RSLogix processors? In a ControlLogix processor, ladder logic is entered in: Tasks, Routines.

  Implenting a code

Write down a fragment of code which reads a line of text (using getline) from standard input containing of a last name followed by the first name

  Write down four logic functions that are true

Implement the four functions using a ROM.Assume that X consists of 3 bits, x2 x1 x0

  Make a menu bar with a file menu

make a menu bar with a File menu that includes a Perform Action command and an Exit command. The Perform Action command computes either the sum or average of the rows or columns in the array and displays the result in a message box. The Exit comma..

  How to create a usetvshow.java file

design a class named TVShow.java. Data Fields can include a String containing the Name of the show, a String containing the day that the show is broadcast(i.e. â??Mondayâ?) and an integer for the channel where the show can be viewed.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd