Question: Begin by setting up three variables, target, number _ guess and player _ guess, with initial values of 2 , 0 and 0 , respectively.
Begin by setting up three variables, target, numberguess and playerguess, with initial values of and respectively. Subsequently, establish a while loop that continues to iterate as long as the variable numberguess is less than or equal to Inside the loop, first, increment the value of numberguess by one. Then, using the input function ask the player to make a guess and assign it to the appropriate variable. Then, employ conditional statements to print "Your guess it too low when the variable playerguess is less than the variable target, "Correct guess You won" when it is equal to target, and "Your guess it too high when it is higher than the variable target.
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
