Question: #include int computeTotal ( int scores [ ] , int numHoles ) { / / this function will compute the total score int total =
#include
int computeTotalint scores int numHolesthis function will compute the total score
int total ;
for int i ; i numHoles; i
total scoresi;
return total;
int main
int numHoles ;
int scores;
printfEnter scores for each hole:
;inpute the scores from each hole
for int i ; i numHoles; i
printfHole d: i ;
scanfd &scoresi;
Compute the total score using the computeTotal function
int totalScore computeTotalscores numHoles;Compute score using computeTotal function
printf
Total Score: d
totalScore;display the total scores
iftotalScorethis if statement will determine if the golfer won..If more than than he won
printfYOU WON!!!! Congrats, but you will never beat Tiger Woods
;
else
printfYOU LOST!!!! Please continue practicing";
return ;
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
