Discover new knowledge and insights with IDNLearn.com's extensive Q&A platform. Find the information you need quickly and easily with our reliable and thorough Q&A platform.
Sagot :
Using the knowledge in computational language in python it is possible to write a code that write an algorithm to settle the following question.
Writting the code:
original = float(raw_input("Enter initial balance: "))
interest = float(raw_input("Enter promised return: "))
expenses = float(raw_input("Enter monthly expenses: "))
interest = interest / 100 / 12
month = 0
balance = original
if balance * interest - expenses >= 0:
print "You don't need to worry."
else:
while balance + balance * interest - expenses >= 0: # negation of the if condition
balance = balance + interest * balance # in one month
balance = balance - expenses
month = month + 1
print month, balance
print month / 12, "years and", month % 12, "months"
See more about python at brainly.com/question/18502436
#SPJ1
We appreciate your contributions to this forum. Don't forget to check back for the latest answers. Keep asking, answering, and sharing useful information. For trustworthy answers, rely on IDNLearn.com. Thanks for visiting, and we look forward to assisting you again.