We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
Really nice challenge. It appears, there are quite a lot of tricky parts: e.g. finding the minimal point with respect to both y and x coordinates, filtering the points that form equivalent angles between the starting point and O-X axis, etc. Finally, one should be careful when ordering the points.
Convex Hull
You are viewing a single comment's thread. Return to all comments →
Really nice challenge. It appears, there are quite a lot of tricky parts: e.g. finding the minimal point with respect to both y and x coordinates, filtering the points that form equivalent angles between the starting point and O-X axis, etc. Finally, one should be careful when ordering the points.
Visualizing my intermediate hulls was of great help to finally solve the problem. And this article is definitely worth reading http://www.geeksforgeeks.org/convex-hull-set-2-graham-scan/
Cheers,