← All problemsSign in

Richie and lanes

Richie is passing through an area which is an X - Y plane. There are N lanes numbered 1 to N (Lanes can have any slope in the X-Y plane). Start and endpoint of each lane are given as (a1, b1) and (a2, b2). Lanes have some food shops on the way. Food shops are located at coordinates (a, b) where both a and b are integers, as Richie is very hungry he needs to visit at least k food shops to satisfy h

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.

voice by Sarvam AI

Sign in to chat with the tutor and save your progress.

Sign in to start