Driver code
if __name__ == " _ _ main _ _ " : NEW_LINE INDENT wt = [ 4 , 8 , 9 ] NEW_LINE val = [ 2 , 4 , 6 ] NEW_LINE N = len ( wt ) NEW_LINE K = 2 NEW_LINE print ( maxWeight ( wt , val , K , N ) ) NEW_LINE DEDENT