Chef and his computer lab
CodeChefOpen on judge ↗
Chef has built a computer lab and has n computer in the lab. The physical locations of all the computers is given as coordinates (xi, yi). Now chef wants to connect all the computers in a network using Fiber Optic Cable. He wants to connect all the computers in such a way that every computer is reachable from every other computer (directly or indirectly). Also he wants to minimize the length of ca
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