using System.Collections.Generic;using System.Drawing;publicstaticclassKata{publicstaticboolPolyOrientation(List<PointF> Poly){float sum =0;for(int v =0; v < Poly.Count; v++){int v_prev = v >0? v -1: Poly.Count -1;
sum +=(Poly[v].X - Poly[v_prev].X)*(Poly[v].Y + Poly[v_prev].Y);}return sum >0;}}
using System.Collections.Generic;using System.Drawing;publicstaticclassKata{publicstaticboolPolyOrientation(List<PointF> Poly){float a =0;for(var index =0; index < Poly.Count; index++){var nextPointIndex =(index +1)% Poly.Count;
a +=(Poly[nextPointIndex].X - Poly[index].X)*(Poly[nextPointIndex].Y + Poly[index].Y);}return a >=0;}}