convex_hull_andrew

% Convex Hull — Andrew's Monotone Chain % % Walks 8 sorted points left-to-right building the lower hull via % stack + cross-product turn check, then (compressed) upper hull, % then highlights the final hull polygon. % % Points (sorted by x): % A(0,1) B(1,0) C(2,2) D(3,1) E(4,3) F(5,0) G(6,4) H(7,2) % % Expected result: % Lower hull: A B F H Upper hull: H G A % Full hull (CCW): A B F H G Interior: C D E % % Demonstrates the loop-to-step manual-unroll pattern (ruleset §2.1).

Step 1 / 23