The law of uninhibited growth follows below formula:
A = Pe^(rt)
For your problem, we need to first look for the rate, given the initial and final number of bacteria..
A = Pe^(rt)
800 = (500)(e)^r(1)
(800/500) = (e)^r(1)
ln (8/5) = ln (e) ^ r
r = 0.47
substitute the value of r to get the number of bacteria after 5 hours:
A = Pe^(rt)
A = (500)(e)^(0.47)(5)
A = 5,242.78 or 5,243