Differentiation and proving Prove that if the curve $y=\frac{x^3}{3} + px + q$ is tangent to the straight line $y = x$, then $4(p-1)^3 + 9q^2 = 0$ 
I have differentiated the equation of the curve to get $x^2 + p$ and equated it to $1$.
But i have no idea how to proceed to get the subsequent equation. 

$$y=\frac{x^3}{3} + px + q$$
Therefore $$y'=x^2 + p $$
Thus the gradient of $y=x$ must be equal to $x^2+p$.
That is $$x^2+p=1$$.
Since $y=x$ at each tangent points $x=\sqrt{1-p}$ and $x=-\sqrt{1-p}$ , 
$$x=\frac{x^3}{3} + px + q$$
$$x^2=\frac{x^4}{3} + px^2 + qx$$
$$(1-p)=\frac{{(1-p)}^2}{3} + p(1-p) + qx$$
$$(1-p)-p(1-p)=\frac{{(1-p)}^2}{3} +  qx$$
$$(1-p)(1-p)=\frac{{(1-p)}^2}{3} +  qx$$
$$(1-p)^2=\frac{{(1-p)}^2}{3} +  qx$$
$$\frac{{2(1-p)}^2}{3} =  qx$$
Thus $$\frac{{4(1-p)}^4}{9} =  q^2x^2$$
$$\frac{{4(1-p)}^4}{9} =  q^2(1-p)$$
For $p \neq 1$ ,
$$4(1-p)^3 =  9q^2$$
$$-4(p-1)^3 =  9q^2$$
$$4(p-1)^3 +  9q^2=0$$
