Sunday, April 13, 2014

SPOJ 9380. Connecting Three Towns (THREETWN)

http://www.spoj.com/problems/THREETWN/

  I got around 92% of the total score by solving it this way. If you take the arithmetic mean of 3 coordinates you will get a very good answer if not the best answer.
X=(X1+X2+X3)/3
Y=(Y1+Y2+Y3)/3


       DOWNLOAD THE FULL SOURCE CODE

No comments:

Post a Comment