Question: Consider the following number - guessing game. A target integer chosen from 0 to ( inclusive ) is known only to the referee. A player
Consider the following numberguessing game. A target integer chosen from to inclusive is known only to the referee. A player is given chips and can ask a series of questions to identify the unknown integer as long as a chip is available. Each question must be presented in the form Is the target integer less than where is an integer. The referee will answer the question with either a Yes or a No The referee will always tell the truth. Each Yes costs the player one chip, while a No costs the player nothing. Design a Java program to calculate the minimum number of questions needed to identify any target number for a given and number of chips As input arguments, your program should take in values of and and output the minimum number of questions needed in the worst case. The following command nds the minimum number of questions needed for and java jar Guess.jar and returns the following: Yixin Chen For a target number between and with chips, it takes at most questions to identify the target number in the worst case. Specic requirements of the project include: Use the dynamic programming technique to design your program. pts Explain in English your design and present pseudo code pts Dene the optimal substructure pts ie recurrence. If your program passes all the test cases, you will receive pts Additionally, pts will be awarded for a bottomup implementation. Make an interactive game where a user is a referee, and the program will guess the target integer with the minimum number of questions. Bonus Points: pts Please submit a report, JAVA source code and jar le to Blackboard before Friday, Nov. nd
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
