Notice that your function can be written as the *quotient* of two other functions, let's say #f(x)# and #g(x)#, which means that you can differentiate it by using the quotient rule.

#color(blue)(y^' = (f^'(x) * g(x) - f(x) * g^'(x))/[g(x)]^2#, where #g(x)!=0#

In your case, you have #y = f(x)/g(x)#, where

#f(x) = e^x# and #g(x) = x^2#

This means that your derivative will look like this

#y^' = (d/dx(e^x) * x^2 - e^x * d/dx(x^2))/(x^2)^2#

The derivative of #e^x# is always

#d/dx(e^x) = e^x#, so you get

#f^' = (e^x * x^2 - e^ * (2x))/x^4 = (x * e^x * (x - 2))/x^4#

You can simplify this to be

#f^' = (color(red)(cancel(color(black)(x))) * e^x (x-2))/x^(color(red)(cancel(color(black)(4)))color(blue)(3)) = color(green)((e^x(x-2))/x^3)#