Question: ( 2 5 pts ) You are starting to make a simple game. ( All values should be whole numbers ) ( A ) Write

(25 pts) You are starting to make a simple game. (All values should be whole numbers)
(A) Write a function named updatescore that has four parameters, a, b, c, and score. If the first three arguments are in ascending order by 1,(i.e.1,2,3 or 3,4,5, etc.) it adds 30 to score (changing the argument's value). It (always) returns the sum of the first 3 parameters.
(B) Write a main function that declares four int variables x=3,y=4,z=3 and score =100 and then calls updateScore with these variables and displays the player's sum and new score.
( 2 5 pts ) You are starting to make a simple

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Accounting Questions!