Question: - use 2 different methods to guess the number - method 1: --- using a random number generator to start with a random guess. Remaining
- use 2 different methods to guess the number
- method 1:
--- using a random number generator to start with a random guess. Remaining guesses will be random numbers based on the lower/higher hints
--- count the number of guesses
- method 2:
--- use the algorithm from splitsearch (binary): start with 50 and then use the hints
--- count the number of guesses
after all simulations:
- display the number of simulations and the average number of guesses for random and binary
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
