Skip to content

Instantly share code, notes, and snippets.

@suchov
Created June 22, 2017 19:30
Show Gist options
  • Save suchov/545b02275543b9f17c0424ee0ff62a72 to your computer and use it in GitHub Desktop.
Save suchov/545b02275543b9f17c0424ee0ff62a72 to your computer and use it in GitHub Desktop.
monthlyPayment = 0
monthlyInterestRate = annualInterestRate /12
newbalance = balance
month = 0
while newbalance > 0:
monthlyPayment += 10
newbalance = balance
for month in range(1,13):
newbalance -= monthlyPayment
newbalance += monthlyInterestRate * newbalance
month += 1
print("Lowest Payment: " + str(monthlyPayment))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment