28.4k views
1 vote
At one college, the tuition for a full-time student is $8,000 per semester. It has been announced that the tuition will increase by 3 percent each year for the next 5 years. Write a program with a loop that displays the projected semester tuition amount for the next 5 years.

User RDM
by
5.2k points

1 Answer

1 vote

Answer:

#include <iostream>

using namespace std;

int main () {

// for loop execution

int semester_fees=8000;

int b=1;

cout<<"there are 5 years or 10 semester fees breakdown is given below"<<endl;

for( int a = 1; a <=5; a++ ) {

semester_fees = semester_fees*1.03;

cout<<"Semester fees for each of semester"<<b++<<"and"<<b++<<"is:$"<<semester_fees<<endl;

}

return 0;

}

Step-by-step explanation:

code is in c++ language

Fees is incremented yearly and i have considered only two semester per year

User Janka
by
4.8k points