subject

I have been working on this python program for a hour now, and I am trying to figure out what I an doing wrong in the loop. I have attached the code and screenshot of my work. I need help to figure out how to loop the rest of the years for a calculation. The calculation has looped the same result for all years. This is the assignment:
In 2017, the tuition for a full time student is $6,450 per semester. The tuition will be going up for the next 7 years at a rate of 3.5% per year. Write your python program using a loop that displays the projected semester tuition for the next 7 years. You should display the actual year (2018, 2019, through 2024) and the tuition amount per semester for that year.
Here is my code:
# declare global constant variables
startingTuition = 6450.00;
starting_tuitionYear = 2018;
ending_tuitionYear = 2025;
increment = 1;
rate = .035;
tuition = 0;
tuitionRate = 0;
#loop for the next 7 years
for year in range(starting_tuitionYear, ending_tuitionYear, increment):
# calculate rate per year
tuitionRate = (rate)*startingTuition;
# add rate per year to the tuition fee
tuition = startingTuition + tuitionRate;
print('Tuition for the year of ' + str(year)+ ' is ' + str(tuition));

ansver
Answers: 2

Other questions on the subject: Computers and Technology

image
Computers and Technology, 23.06.2019 14:30, rose6038
Select the correct answer. peter has launched a website that features baby products. however, clients often find they are unable to access the website because the server is down. which feature of cybersecurity should peter focus on for his website? a. data authenticity b. data privacy c. data availability d. data integrity e. data encryption
Answers: 3
image
Computers and Technology, 24.06.2019 21:30, breannaasmith1122
Along what line of action can the camera move to follow the movement of actors for screen direction? a. along a 90-degree arcb. along a 120-degree arcc. along a 180-degree arcd. along a 360-degree arc
Answers: 1
image
Computers and Technology, 25.06.2019 13:10, ayoismeisjjjjuan
1. which characteristics of pop art are evident in the image? select all that apply. (3 points). a. ben-day dots b. bold use of color c. celebrity figure d. everyday object
Answers: 3
image
Computers and Technology, 26.06.2019 03:20, abilovessoftball
The reliability of a hard-disk drive is typically described in terms of a quantity called mean time between failures (mtbf). although this quantity is called a “time,” the mtbf actually is measured in drive-hours per failure. if a system contains 1,000 disk drives, each of which has a 750,000-hour mtbf, which of the following best describes how often a drive failure will occur in that disk farm: once per thousand years, once per century, once per decade, once per year, once per month, once per week, once per day, once per hour, once per minute, or once per second?
Answers: 1
You know the right answer?
I have been working on this python program for a hour now, and I am trying to figure out what I an d...

Questions in other subjects: