Driver code
int main ( ) { int arr [ ] = { 3 , 6 , 7 , 13 } ; int n = sizeof ( arr ) / sizeof ( arr [ 0 ] ) ; if ( solve ( arr , 0 , 0 , n ) ) { cout << " YES " ; } else { cout << " NO " ; } return 0 ; }