Question: Extend / modify the previous part to include the following: Use a while statement to create a loop that allows the user to play multiple
Extendmodify the previous part to include the following:
Use a while statement to create a loop that allows the user to play multiple rounds of guessing the year game.
Implement a scoring system:
Award points for correct guesses on the first attempt.
Award points for correct guesses on the second attempt.
Award point for correct guesses on the third attempt, else no points awarded.
After each round, prompt the user to confirm if they want to continue playing.
Keep track of the total score across all rounds.
When the user decides to stop, display their final score and a rank based on their performance:
points: SHI.ELD Recruit"
points: "Avenger in Training"
points: "Earth's Mightiest Hero"
points: "Guardian of the MCU Timeline"Sample output
Enter filename: moviestxt
WELCOME TO THE SHIELD DATABASE
Iron Man es
Thor
Captain Anerica: The First Avenger
Doctor Strange
SpiderMan: Honeconing
Black Panther
Captain Anerica: The Winter Soldier
The Avengers
SpiderMan: No Way Hone
Enter a number between :
The novie is SpiderMan: Horecoming
Guess the release year:
Correct! Well done, Agent!
Attempt
Guess the release year:
Attempt
Your guess is lower
Guess the release year:
Correct! Well done, Agent!
Your current score is
Do you want to continue :
Enter a movie: Iron Man
Attempt
Guess the release year:
Attempt
Your guess is higher
Guess the release year:
Attempt
Hint:
Guess the release year:
Correct! Well done, Agent!
Your current score is
Do you want to continue :
Game Over! Your final score is
Your rank is Avenger in Training
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
