Question
c++ launguage please help The game Pico Fermi Bagel is a number guessing game. The computer picks a secret number: the secret number must be
c++ launguage please help
The game Pico Fermi Bagel is a number guessing game. The computer picks a secret number: the secret number must be 3 digits, none of the digits can be the same, and it cannot start with a zero. 104 is OK, but 091 and 212 are not. The user tries to guess the secret number - if none of the digits in the user's number are in the secret number, then the program replies with BAGEL (or B). For each digit in the user's number that is in the secret number but not in the right place value, the program replies PICO (or P). For each digit in the user's number that is in the secret number and is in the right place, the program replies FERMI (or F). When the user has Fermi Fermi Fermi (FFF) the secret number has been found.
In a file, write the secret number, then write the user guess and its result (e.g. 123 B, 456 FF, 789 P, 846 FFF). When the user wins, write the number of guesses it took. Allow the user to quit the program and allow the user to play again. If the user quits, display the secret number.
After your project is complete, you will be assessed on the following:
- Generating random numbers
- Use of the modulus
- Text file operations : writing a file
- Conditionals : if, if-else, switch
- Loops : while, do-while, for
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started