

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Community
Ask the community for help and clear up your study doubts
Discover the best universities in your country according to Docsity users
Free resources
Download our free guides on studying techniques, anxiety management strategies, and thesis advice from Docsity tutors
Instructions for assignment 05 in csci 230, fall-2006. Students are required to write a fortran program to compute monthly payments for a loan with given loan amount, annual interest rate, and number of years. The program should also compute the amounts of interest, principles, and balance for each month and for each year.
Typology: Assignments
1 / 3
This page cannot be seen from the preview
Don't miss anything!
Part I (40 points) Step 1. From the course web page (http://www.cs.niu.edu/~sjchung), copy Prog05a.for and Prog05a.sjc into your f drive. And, get printed copies of both files. Step 2. Compile & link/edit your Prog05a.for to get Prog05a.obj and Prog05a.exe. Step 3. Run your Prog05a.exe by: h:> Prog05a.exe > Prog05a.out Your Prog05a.out should compare correctly to Prog05a.sjc. Step 4. Study Prog05a.for and Prog05a.out. Understanding them will help you do the problems on Page 2 of this Assignment and write Prog05b.for. Step 5. Complete the problems on Page 2 of this assignment. Part II (60 points) Write a FORTRAN program that will prompt the user to enter Loan Amount (A), Annual Rate (R) of interest, and Number (N) of years to finance the loan, then compute the monthly payment (P) for the given A, R, and N. In addition, your program will compute the amounts of interest, principles, and balance for each month and for each year. The output by your program must display the amounts for each month of the first year, followed by the annual reports. Step 1. From the course web page (http://www.cs.niu.edu/~sjchung), copy Prog05b.in and Prog05b.sjc into your H drive. And, get printed copies of both files. In case you need help, there is Prog05b.ref that you can use. Step 2. Name your source program as Prog05b.for, and complete it. Your Prog05b.for must be well structured, and must demonstrate your knowledge on the use of FUNCTION and SUBROUTINE subprograms. As always, your source program (Prog05b.for) must be well documented. Step 3. Compile & link/edit your Prog05b.for to get Prog05b.obj and Prog05b.exe. Step 4. Run your Prog05b.exe by: f:>Prog05b < Prog05b.in | more (to see the next page of the output, press the
Hand in :
If a loan of A dollars at an annual interest rate R is to be paid off in N years, and if the interests are compounded yearly, then the annual payment P is given by (see Ex.8, p.245): p = A(
N N