Driver program to test maxSubArraySum
int main ( ) { int arr [ ] = { 2 , 3 , 4 , 5 , 7 } ; int n = sizeof ( arr ) / sizeof ( arr [ 0 ] ) ; int max_sum = maxSubArraySum ( arr , 0 , n - 1 ) ; printf ( " Maximum ▁ contiguous ▁ sum ▁ is ▁ % d STRNEWLINE " , max_sum ) ; getchar ( ) ; return 0 ; }