25 POINTS!!

Consider a square and a regular hexagon (a six sided figure with sides of equal length). One side of the square is 8 feet longer than a side of the hexagon, and the two figures have the same perimeter. What are the lengths of the sides of each figure?