text: Driver program to test above functions
code: int main ( ) { int arr [ ] = { 1 , 5 , 8 , 9 , 10 , 17 , 17 , 20 } ; int size = sizeof ( arr ) / sizeof ( arr [ 0 ] ) ; cout << " Maximum ▁ Obtainable ▁ Value ▁ is ▁ " << cutRod ( arr , size ) ; getchar ( ) ; return 0 ; }