Can anyone telling me why my program is returning a negative number at the end...attached is the program I have created any help would be appreciated thank you:
/*Write a recursive function recursiveMinimum that takes an integer array and
the array size as arguments and returns the smallest element of the array. The
function should stop processing and return when it receives an array of 1 element.*/
when I ran it I did not see a negative number, so what numbers are you using ?
c:\temp>test124
Enter number 1: 124
Enter number 2: 235
Enter number 3: 111
Enter number 4: 2
Enter number 5: 3
Enter number 6: 5
Enter number 7: 8
Enter number 8: 9
Enter number 9: 6
Enter number 10: 0
9 0 0
The minimum number is: 0