Zoho (India) interview question

minimum cost to connect ropes