You think you can count
CodeChefOpen on judge ↗
You are given the vertices of a $N$ sided convex polygon on a 2D cartesian plane. You have to answer $Q$ queries. Each query consists of four space separated integers $x1, y1, x2, y2$ where the point $(x1, y1)$ lies on any one side of the given polygon and the point $(x2, y2)$ lies on any other side of the polygon. Upon joining these two points, the polygon is divided into two smaller polygons le
HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17
CodeSearch Tutor
Hints, not spoilers — it won’t hand over the full solution unless you insist.
Sign in to chat with the tutor and save your progress.
Sign in to start