
Gaurav P. answered 07/26/20
Computer Science Student with Teaching Experience
If you start off with $1 in your account and it doubles every day, it goes up to $2 one day later, then $4 the day after, then $8, then $16, then so on. Essentially, every successive day, it gets multiplied by 2.
There is a mathematical operator that can represent multiplying a number multiple times: the exponent operator, or ab. Essentially, ab means "multiply a by itself, b times".
We can represent the value in your bank account like this: if x days have passed, then the balance in your account is 2x, or 2 multiplied by itself, x times.
Your friend's bank account, on the other hand, starts off at $100,000, then increases to $10,000 every day. Their balance after x days can thus be represented as 10,000x + 100,000.
We can then set up an equation to see when both amounts will be equal: 2x = 10,000x + 100,000.
To solve this equation, we can try plugging different values for x, and see which one gives us the closest result on both sides. Let's try an initial guess, 10 days: 210 = 1024, and 10,000(10) + 100,000 = 200,000. Far off, and probably not the right answer. Let's try again, 15 days. 215 = 32,768, and 10,000(15) = 250,000. Closer, but still pretty far. Let's try 20: 220 = 1,048,576, and 10,000(20) + 100,000 = 300,000. Overshot it slightly.
Let's try, I don't know, 18: 218 = 262,144, and 10,000(18) + 100,000 = 280,000. That seems like the closest match, but to verify, we'll check 17 and 19, and if you check those yourself using a calculator, you'll see that those are much further off, so 18 is the closest.
The question asks for not only the number of days when they'll be equal, but also what the dollar amounts are; as we've plugged our x into both sides of the equation, we have the answers to those as well. So, our final answer is: the bank accounts will have close to the same amount of money after 18 days, at which point your account will have $262,144, and your friend's will have $280,000.