← All problemsSign in

Wiring

A Government of merryland is planning to power the city. The city is divided into AxB blocks, each block has either house(H), transformer(T) or empty land(E). The wiring to a block can be done only if the block is vertically or horizontally adjacent to a wired block. The wiring to an empty block is not done as there are no houses there. The cost of providing electricity to a particular block in th

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