The current centroid calculation works correctly for squares and rectangles, but it does not produce accurate results for four-sided polygons. Update the implementation to correctly calculate the ...