Your restriction is the the volume must be 240
The volume in each box is given by so
The area of wire that is needed is the sum of the surface areas
You want to minimise A so first get A in terms of only x, then find when equals zero, confirm that it is a minimum for the area not a maximum. You will probably get 2 answers, remember than you are restricted in how big/small x can be.