# Thread: How to differentiate this e function

1. ## How to differentiate this e function

y = 2 - xe^x

I got:

= d(2) + d(-x)(e^x) + d(e^x)(-x)
dx dx dx

= 0 + (1)(e^x) + (e^x)(-x)

= e^x - xe^x

= e^x (x-1)

But I don't know if I am correct?

Appreciate all help, thanks in advanced!

2. = d(2) + d(-x)(e^x) + d(e^x)(-x)
dx dx dx

= 0 + (1)(e^x) + (e^x)(-x)
I think you dropped a minus sign
$\frac{d(-x)}{dx} = -1$