Errors in lists

Report a typo

You've created a list of games you plan to buy. After some consideration, you decided to remove 'chess' from this list. Your goal is to print both the updated list of games and the game you removed.

The provided code contains errors. Identify and correct them.

After correcting the errors, the code should:

  1. Remove 'chess' from the list

  2. Print the updated list of games

  3. Print the name of the removed game

Write a program in Python 3
games = ['backgammon', 'Scrabble', 'chess', 'battleship', 'Monopoly']
removed_game = games.remove(3)

print("The resultant list of games:")
print(games)
print("The removed game:")
print(removed__game)
___

Create a free account to access the full topic