As you can see I'm using a Function to data-validation the, but I cant get the lowest score Function to work. I'm new to Function so it may be some think easy that I over looked. Again any help would be nice and Thank You for your time.
To begin with, you're passing the variable "lowest" from main () to findLowest() by value. These are two separate variables; that they have the same name is irrelevant.) I recommend you pass it by reference, or use the return argument to get the value derived back to main(). The way you're doing it, the lowest in findLowest gets derived, then disappears when the function returns.
Also, I think you've introduced more complexity than is necessary. You also seem to be confusing the judge with the score the judge has awarded. Also, the same comment about passing the variable "judge" by value applies. Plus, I think the double variable judge should be called something like "score" for clarity, but this won't affect the way the program runs.
Try tackling these changes first, then let's see how it's working.
Thank you for your reply, I have been reading up on reference but I don't fully understand them. All so I have add the return lowest; like you suggested but I still cant get it to work right.
Hm, findLowest(double lowest) doesnt do anything, since you overwrite your lowest variable with 15 in the second line. Also, judge is a random value since you havent initialized it.
Also, in your first code, you never catch the variable returned by getJudgeScore(judge).
You need to use pointers if you want your functions to affect the variables in your main program, since your function gets only a copy of your judge and lowest variables, completely ignoring the original ones.
So, the main problem here is that you dont realize that the lowest and judge variables in your functions are totally different from the ones in your main program, all are local, never affect each other.
Also, you make your function a return which you never assign to anything..
OK, I realize that I'm skipping around here, but...you do realize that your cout calls in main() are missing valid functions, right? Parens, parameters, etc).
Also, if your professor isn't going to allow you to use for loops, is he going to allow do/while loops? That doesn't make much sense.