(Challenge) Raisins
CodeChefOpen on judge ↗
Chef Ada baked a rectangular cake with width $W$ and height $H$. To finish the cake, she placed $R$ raisins on it. For simplicity, we will represent raisins by points in a plane. For each valid $i$, the position of the $i$-th raisin is $(X_i, Y_i)$. The price of the cake is twice the area of the smallest convex polygon that contains all raisins. Ada thinks that the current price is too high, so
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