An equilateral triangle and a square have the same perimeter. Each side of the square measure 6cm. What is the length of each side of the triangle?