C # implementation of the above approach
using System ; using System . Collections . Generic ; class GFG { static List < int > [ ] graph = new List < int > [ 100 ] ; static String [ ] weight = new String [ 100 ] ;