This is a difficult question that you only need to know the result of.However, it's a good exercise to derive it.
Starting with f(x)=ax we can take the natural logarithm of both sides (so we can use one of its properties).
This gives us ln(f(x))=ln(ax), from the natural logarithms properties we know this is equal to ln(f(x))=x*ln(a).
Now using the chain rule we can differentiate both sides,
d(ln(f(x)))/dx= f'(x)/f(x), d(x*ln(a))/dx=ln(a)
so we now have f'(x)/f(x)=ln(a). Recalling that f(x)=ax this gives us the answer,
f'(x)=axln(a).