calculator updates '=' button

This commit is contained in:
2023-06-09 19:33:41 +10:00
parent a81359a274
commit 95ff2e7e46
3 changed files with 22 additions and 1 deletions

View File

@@ -15,13 +15,17 @@ games = ["Left 4 Dead 2",
"Magicka 2",
]
def add_game(game: str):
games.append(game)
def pick_game():
randomIndex = random.randrange(0, len(games))
coinFlip = random.randrange(0, 2)
if coinFlip:
return "Valorant"
return f"Valorant ({games[randomIndex]})"
else:
return games[randomIndex]