-
Notifications
You must be signed in to change notification settings - Fork 1
/
main.py
45 lines (39 loc) · 1008 Bytes
/
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
import ascii_art
from blackjack import play_blackjack
from horse_betting import play_horse_betting
from slot_machine import play_slot_machine
from roulette import play_roulette
print(ascii_art.title)
menu = '''
What would you like to play?
1 -> Blackjack
2 -> Roulette
3 -> Slot Machine
4 -> Horse Betting
5 -> Exit
'''
casino = True
while casino:
new_number = True
while new_number:
try:
print("\n"+menu)
game = int(input("Enter game option: "))
new_number = False
except ValueError as error:
print("Please enter a number")
match game:
case 1:
play_blackjack()
case 2:
play_roulette()
case 3:
play_slot_machine()
case 4:
play_horse_betting()
case 5:
casino = False
print("Thank you for playing in the casino!")
print(ascii_art.goodbye)
case _:
print("You chose an invalid option")