Find the critical points, the second derivative, and local minimum and maximum

Recall that a critical point is a point in the domain of the function where the function is either not differentiable or the derivative is equal to zero.
1) The first derivative of the given function is:
[tex]\begin{gathered} f^{\prime}(x)=-e^x(x-9)+(-e^x)*1 \\ =-e^x(x-9+1)=-e^x(x-8). \end{gathered}[/tex]Notice that f'(x) is the product of two continuous functions, then it is continuous.
Setting f'(x)=0 we get:
[tex]0=-e^x(x-8).[/tex]Then:
[tex]e^x=0\text{ or }x-8=0.[/tex]We know that for all x real number:
[tex]e^x>0.[/tex]Then:
[tex]\begin{gathered} x-8=0, \\ x=8. \end{gathered}[/tex]Answer 1:
Option A) The critical point(s) is(are) x=8.
2) Now, notice that f''(x) is the derivative of f'(x), then:
[tex]\begin{gathered} f^{\prime}^{\prime}(x)=(-e^x(x-8))^{\prime}=-e^x(x-8)+(-e^x*1) \\ =-e^x(x-7). \end{gathered}[/tex]Now, evaluating f''(x) at x=8 we get:
[tex]f^{\prime}^{\prime}(8)=-e^8(8-7)=-e^8<0.[/tex]Using the second derivative test we get that f(x) reaches a local maximum.
Answer 2:
[tex]f^{\prime}^{\prime}(x)=-e^x(x-7).[/tex]f(x) reaches a local maximum at x=8.