diff --git a/contents/jarvis_march/code/c++/jarvis_march.cpp b/contents/jarvis_march/code/c++/jarvis_march.cpp index d2d420957..0e8c7acb1 100644 --- a/contents/jarvis_march/code/c++/jarvis_march.cpp +++ b/contents/jarvis_march/code/c++/jarvis_march.cpp @@ -50,15 +50,21 @@ std::vector jarvis_march(const std::vector& points) int main() { std::vector points = { - { 1.0, 3.0 }, - { 1.0, 3.0 }, - { 2.0, 4.0 }, - { 4.0, 0.0 }, - { 1.0, 0.0 }, - { 0.0, 2.0 }, - { 2.0, 2.0 }, - { 3.0, 4.0 }, - { 3.0, 1.0 }, + { -5.0, 2.0 }, + { 5.0, 7.0 }, + { -6.0, -12.0 }, + { -14.0, -14.0 }, + { 9.0, 9.0 }, + { -1.0, -1.0 }, + { -10.0, 11.0 }, + { -6.0, 15.0 }, + { -6.0, -8.0 }, + { 15.0, -9.0 }, + { 7.0, -7.0 }, + { -2.0, -9.0 }, + { 6.0, -5.0 }, + { 0.0, 14.0 }, + { 2.0, 8.0 } }; auto hull_points = jarvis_march(points); @@ -69,4 +75,3 @@ int main() { std::cout << '(' << point.x << ", " << point.y << ')' << std::endl; } } -