Driver Code
if __name__ == " _ _ main _ _ " : NEW_LINE INDENT n = 3 NEW_LINE m = 4 NEW_LINE vp = [ [ [ 1 , 2 ] , [ 2 , ' B ' ] ] , [ [ 1 , 2 ] , [ 3 , ' W ' ] ] , [ [ 2 , 3 ] , [ 4 , ' W ' ] ] , [ [ 2 , 3 ] , [ 5 , ' B ' ] ] ] NEW_LINE makeGraph ( vp , m ) NEW_LINE print ( getCost ( n , m ) ) NEW_LINE DEDENT