Build the roads

Problem Name:
Build the roads
Site:HackerEarth
Links:
Tags: