Given a past population of 45234000 and a present population of 51321000 and the growth rate is 0.5 how do i calculate the number of years

Given a past population of 45234000 and a present population of 51321000 and the growth rate is 0.5 how do .i calculate the number of years.

51,321,000 / 45,234,000 = 1.005^n

1.1345669.... = 1.005^n

n = Log(1.1345669) / Log(1.005)

n = ~25.3 years.