hi,i wqas having a hard time solving this problem...any help would be great

Consider a rectangle of perimeter of 12 inches. We obtain a cylinder by gluing vertical side to the other vertical side. Find the dimensions of the rectangle so that the cylinder has maximal volume.