S_bal = float(input("How much money is your start balance ? $ "))
monthly_dep = float(input("How much additional money will you be putting into your account ? $ "))
int_rate = float(input("How much is your interest rate (1.75% enter 1.75) " ))
years = int(input("How many years are you going to invest? "))
rate = int_rate / 100
months = years * 12
m_int = S_bal * rate / 12
E_bal = S_bal + m_int + monthly_dep
S_bal = E_bal
c_mo = months + 1
while(c_mo <= months):
m_int = S_bal * rate / 12
E_bal = S_bal + m_int + monthly_dep
S_bal = E_bal
c_mo = months
print("Start Balance","Monthly Interest","End Balance")
print(S_bal, m_int, E_bal)
print(round(S_bal,2), round(m_int,2), round(E_bal,2))
I was wondering what I'd have to fix in order to get the loop to display this, what coding would help fix the formatting issue, and if someone could help me check my math ?
I can fully understand how to write it out, but when it comes to coding I lack execution