Answer:
The correct answer is: The instructions are not correctly ordered.
Explanation:
The instructions are not correctly ordered because to pay the cashier, you first have to select your purchases.
The correct order for the instructions:
- Drive to the store.
- Select your purchases.
- Pay the cashier.
- Drive home.
Answer:
- init_balance = float(input("Initial balance: "))
- interest = float(input("Annual interest rate in percent: "))
-
- montly_interest = (interest / 100) / 12
- current_amount = init_balance + init_balance * montly_interest
- print("After first month: %.2f " % current_amount)
-
- current_amount = current_amount + current_amount * montly_interest
- print("After second month: %.2f " % current_amount)
-
- current_amount = current_amount + current_amount * montly_interest
- print("After third month: %.2f " % current_amount)
Explanation:
The solution code is written in Python.
Firstly, prompt user to input initial balance and annual interest rate using input function (Line 1 - 2).
Next, divide the annual interest by 100 and then by 12 to get the monthly interest rate (Line 4).
Apply the formula to calculate the current amount after adding the monthly interest (Line 5) and display the current month after first month (Line 6).
Repeat the same steps of Line 5 - 6 to calculate amount after two and three months and display print them to console. (Line 8 - 12).