scent Posted October 30, 2011 Posted October 30, 2011 (edited) Using the For,While,If loops: One bank pays 5.5 percent annual interest, while a second bank pays4.5 percent annual interest. Determine how much longer it will take to accumulate at least $50 000 in the second bank account if you deposit $1000 initially and $1000 at the end of each year. This is what I have so far, I know that I'm looking for t when A is at or above $50000 but I'm a bit stuck as to how to set it up so that it will calculate A for each t from 1 through 99 and than store that value of t. the loop will end when A is 50000. /working Edited October 30, 2011 by scent
scent Posted October 30, 2011 Author Posted October 30, 2011 (edited) Ok, this is what I have so far: The thing is I'm suppose to determine how much longer it takes the second bank to reach 50000. To do this I know that I will have to have some kind of count for the first bank and second bank, so when the first bank reaches 50k it stops, the program record the t and then when the second bank reaches 50k, the program record that t and the difference of the two will give me the answer. I'm getting stuck as to go about using the counter and ending the loop. Edited October 30, 2011 by scent
Bignose Posted October 30, 2011 Posted October 30, 2011 you want a 'while' loop. Do statement(s) while condition X is true.
scent Posted October 30, 2011 Author Posted October 30, 2011 (edited) /got it Edited October 30, 2011 by scent
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now