Driver code
public static void Main ( String [ ] args ) { int [ ] w = { 3 , 4 , 5 } ; int [ ] val = { 30 , 50 , 60 } ; int n = w . Length ; int C = 8 ; Console . WriteLine ( maxWeight ( w , val , n , C ) ) ; } }