We know that,
Volume of cube = a3, where a = side of cube
According to the question,
Side of first cube, a1 = 3 cm
Side of second cube, a2 = 4 cm
Side of third cube, a3 = 5 cm
Let us assume that the side of cube recast from melting these cubes = a
We know that the total volume of the 3 cubes will be the same as the volume of the newly formed cube,
Volume of new cube = (volume of 1st + 2nd + 3rd cube)
⇒ a3 = a13 + a23 + a33
⇒ a3 = (3)3 + (4)3 + (5)3
⇒ a3 = 27 + 64 + 125 = 216
⇒ a = 6 cm
Therefore, side of cube so formed is 6 cm.