Let's use the method of Lagrange multipliers. We have the Lagrangian
[tex]L(x,y,z,\lambda_1,\lambda_2)=xyz+\lambda_1(x+z-24)+\lambda_2(y+z-24)[/tex]
with partial derivatives (set equal to 0)
[tex]L_x=yz+\lambda_1=0[/tex]
[tex]L_y=xz+\lambda_2=0[/tex]
[tex]L_z=xy+\lambda_1+\lambda_2=0[/tex]
[tex]L_{\lambda_1}=x+z-24\implies x+z=24[/tex]
[tex]L_{\lambda_2}=y+z-24\implies y+z=24[/tex]
From the last two equations, we have
[tex]x+z=y+z\implies x=y[/tex]
so that
[tex]L_z=x^2+\lambda_1+\lambda_2=0[/tex]
Then
[tex]L_z-L_y-L_x=x^2-2xz=x(x-2z)=0\implies x=0\text{ or }x=2z[/tex]
If [tex]x=0[/tex], then [tex]y=0[/tex] and [tex]z=24[/tex], so one critical point occurs at (0, 0, 24) with a value of [tex]p(0,0,24)=0[/tex].
If [tex]x=2z[/tex], then [te]y=2z[/tex] and [tex]z=8[/tex], making [tex]x=y=16[/tex] and giving another critical point at (16, 16, 8) with a value of [tex]p(16,16,8)=2048[/tex].