-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcode.py
More file actions
70 lines (47 loc) · 1.71 KB
/
Copy pathcode.py
File metadata and controls
70 lines (47 loc) · 1.71 KB
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
class EventManager(object):
def __init__(self):
print("Event Manager:: Let me talk to the folks\n")
def arrange(self):
self.hotelier = Hotelier()
self.hotelier.bookHotel()
self.florist = Florist()
self.florist.setFlowerRequirenments()
self.caterer = Caterer()
self.caterer.setCuisine()
self.musician = Musician()
self.musician.setMusicType()
class Hotelier(object):
def __init__(self):
print("Arranging the Hotel for Marriage? --")
def __isAvailable(self):
print("Is the Hotel free for the event on given day?")
def bookHotel(self):
if self.__isAvailable():
print("Registered the Booking\n\n")
class Florist(object):
def __init__(self):
print("Flower Decorations for the Event? --")
def setFlowerRequirenments(self):
print("Carnation, Roses, and Lilies would be used for Decorations\n\n")
class Caterer(object):
def __init__(self):
print("Food Arrangements for the Event --")
def setCuisine(self):
print("Chinese & Continental Cuisine to be served\n\n")
class Musician(object):
def __init__(self):
print("Musical Arrangements for the Marriage --")
def setMusicType(self):
print("Jazz and Classical will be played\n\n")
class You(object):
def __init__(self):
print("You:: Whoa! Marriage Arrangements??!!!")
def askEventManager(self):
print("You:: Let's contact the Event Manager\n\n")
em = EventManager()
em.arrange()
def __del__(self):
print("You:: Thanks to Event Manager, all preparations done! Phew!")
if __name__ == "__main__":
you = You()
you.askEventManager()