Let's write the volume as a function of x and then take its derivative, figure out where the derivative is 0, and hope that that's a maximum point and we'll prove it by taking the second derivative and seeing.