Question: / * * * Gets menu choice 1 through maxChoice, inclusive * * @param maxChoice, maximum choice index, a number between 2 and 9 ,

/**
* Gets menu choice 1 through maxChoice, inclusive
*
* @param maxChoice, maximum choice index, a number between 2 and 9, inclusive
* @return the first legal choice input, could be 1 through maxChoice, inclusive
*/
unsigned int getMenuChoice(unsigned int maxChoice){
/**
* You may change this in your program, but first please get it working here with this function signature.
* TIPS: take the input in a loop, check that it is in range, and exit the loop only once it is.
* You will handle clearing the screen and printing the menu elsewhere,
* so here just get character(s) or number(s) from the user and do not print error messages.
*/
// TODO: your code here,
// return the value
}

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 Databases Questions!