Question

For this program you will be looking at future tuition at your university. In 2020, the...

For this program you will be looking at future tuition at your university. In 2020, the tuition for a full time student is $6,540 per semester, the tuition for a part time student is $3,320. The tuition will be going up for the next 7 years at a rate of 3.5% per year. Write a program using if-else and a loop. Ask the user if they are a full time or part time student, then display the projected semester tuition for the next 7 years. You should display the actual year (2021, 2022, through 2027) and the tuition amount per semester for that year.

REMEMBER to write your name through comments in the program, and use comments to explain what your program is doing.

(please don't forget the comments)

Homework Answers

Answer #1

#include <iostream>

using namespace std;

int main()
{
char student_type;
int full_tution_fee=6540,part_tution_fee=3320;
cout<<"Enter F for full time student or P for part time student:-";
cin>>student_type;
  
if(student_type=='F' ||student_type=='f' )
{
for(int i=2021;i<=2027;i++)
{
cout<<"Fees for first semester for year "<<i<<" is =$"<<full_tution_fee<<endl;
cout<<"Fees for second semester for year "<<i<<" is =$"<<full_tution_fee<<endl;
full_tution_fee +=0.035*full_tution_fee;
}
  
}
  
else if(student_type=='P' ||student_type=='p' )
{
  
for(int i=2021;i<=2027;i++)
{
cout<<"Fees for first semester for year "<<i<<" is =$"<<part_tution_fee<<endl;
cout<<"Fees for second semester for year "<<i<<" is =$"<<part_tution_fee<<endl;
part_tution_fee +=0.035*part_tution_fee;
}
  
}
  
else
cout<<"invalid input";

return 0;
}

//this code handles the price in two variables- full_tution_fee and part_tution_fee.
//User just need to enter f or p depending on the full time or part time student.
//The user value is cross checked in "if statement" and procedded accordingly.
//After checking the condition the loop is executed 7 times representating each year and the fees
//is updated in every time loop is executed.

Know the answer?
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for?
Ask your own homework help question
Similar Questions
Part A. Input Validation (Name your C program yourLastName_yourFirstName_Lab4a.c) 1. Place the code you developed in...
Part A. Input Validation (Name your C program yourLastName_yourFirstName_Lab4a.c) 1. Place the code you developed in Lab 2 to obtain a diameter value from the user and compute the volume of a sphere (we assumed that to be the shape of a balloon) in a new program, and implement the following restriction on the user’s input: the user should enter a value for the diameter which is at least 8 inches but not larger than 60 inches. Using an if-else...
Financial Application: Compute Future Tuition: For current Nashua College students the tuition cost for 12 credits...
Financial Application: Compute Future Tuition: For current Nashua College students the tuition cost for 12 credits is $2112 per semester, with an additional Technology cost of $120 per semester. In addition, Health Insurance costs add an additional $1595 per semester.             “Scott” is 10 years old (in 2020), and he would like to attend Nashua Community College and major in IT when he turns 18, 8 years from now. If we assume annual costs will increase 5% per year into...
Suppose that you are planning to pay for your child’s college tuition. Your child was just...
Suppose that you are planning to pay for your child’s college tuition. Your child was just born, and all-four- years of college tuition for your child will be due exactly on the child’s 18 th birthday (i.e. all payments at end of year 17). You think for the first 8 years you can afford to set aside $4,000 per year (with the first deposit being made at the end of the first year). How much will you have to save...
Assignment #4 – Student Ranking : In this assignment you are going to write a program...
Assignment #4 – Student Ranking : In this assignment you are going to write a program that ask user number of students in a class and their names. Number of students are limited to 100 maximum. Then, it will ask for 3 test scores of each student. The program will calculate the average of test scores for each student and display with their names. Then, it will sort the averages in descending order and display the sorted list with students’...
Your son is about to start kindergarten in a private school. Currently, the tuition is $12,000...
Your son is about to start kindergarten in a private school. Currently, the tuition is $12,000 per year, payable at the start of the school year. You expect annual tuition increases to average 6% per year over the next 13 years. Assuming that you son remains in this private school through high school and that your current interest rate is 6%, then the present value of your sonʹs private school education is closest to:
Your oldest son is about to start kindergarten at a private school. Tuition is $8,000 per...
Your oldest son is about to start kindergarten at a private school. Tuition is $8,000 per year, payable at the beginning of the year. You expect to keep your son in private school through high school, and you expect tuition to increase at a rate of 4% per year over the 13 years of schooling. Calculate the present value of the tuition payments assuming a required rate of return of 7%. (Round to two decimals).
Assume that you would like to make 6 yearly deposits for your kid’s college tuition fee...
Assume that you would like to make 6 yearly deposits for your kid’s college tuition fee starting today. The initial deposit for today is $10000 dollars and each year the amount increases by $1000. The interest rate is assumed to be 8% per year. a) Draw the cash flow diagram (CFD). b) Assuming that your kind needs the tuition money as a lump-sum amount, 10 years from now. Find the total amount of money that will be accumulated in the...
You would like to set aside money for your child’s education at a 4-year college. Tuition...
You would like to set aside money for your child’s education at a 4-year college. Tuition payments will begin in exactly 18 years and will be paid for 4 consecutive years at the child’s 18th, 19th, 20th, and 21st birthdays. It is estimated that the full cost of the child’s education will be $60,000 per year. Assume interest rate to be 5%. - What is the amount needed to meet this cost exactly at 18 years? - What is the...
Suppose you have a newborn child and want to begin covering estimated cost of tuition and...
Suppose you have a newborn child and want to begin covering estimated cost of tuition and expenses for four years of college beginning 18 years from now. Your estimated cost is $40,000 per year beginning at the end of year 18 and running through the end of year 21 (4 years). Assume a nominal investment interest rate of 8% compounded annually. a. What is the value of the payments at the beginning of year 18 (end of year 17)? b....
Suppose you have a newborn child and want to begin covering the estimated cost of tuition...
Suppose you have a newborn child and want to begin covering the estimated cost of tuition and expenses for four years of college beginning 18 years from now. Your estimated cost is $42,000 per year beginning at the end of year 18 and running through the end of year 21 (4 years). Assume a nominal interest of 15% compounded annually. A) What is the value of the payments at the beginning of year 18 (end of year 17)? B) How...
ADVERTISEMENT
Need Online Homework Help?

Get Answers For Free
Most questions answered within 1 hours.

Ask a Question
ADVERTISEMENT