500$ is invested at 8.5% compounded annually. Find how long it will take until the fund grows to $800

The function g(x)= 23(1-.06)^x gives the Celsius temperature in x minutes after a large quantity of ice has been added to a bowl of water. When will the water reach 5 degrees Celsius?

I am assuming that the 1-.06 is actually 1.06. Therefore...

g(x) = 5
5 / 23 = .21739
log(.21739) = x * log(1.06)
log(.21739) / log(1.06) = x = -26.18999

For the first problem:
A = Pe^(rt)
800 = 500 * e^(0.085 * t)
800 / 500 = 1.6
1.6 = e^(0.085 * t)
Because ln() cancels out e^():
ln(1.6) = 0.085 * t
ln(1.6) / 0.085 = t = 5.52945
Just kidding. That was for continuous compounding, but it isn't too much different and the method is the same, but you use the formula:
A = P(1+(r/n))^(nY)
r = rate
n = number of compoundings per year
Y = number of years
If you use this formula you get, Y = 5.76 years.
You will have to use log() rather than ln().