Computer Project
Computer Project
(2023-25)
COMPUTER
SCIENCE(08
3)
SUb
PROJECT FILE
Submitted by : Devansh Kumar
Class : XII S4
ACKNOWLEDGEMENT
I would also like to thank my classmates and friends for their support and
inspiration. Your encouragement helped me stay motivated and focused
during the project.
Sincerely,
Devansh Kumar
ABOUT THE PROJECT
Project Title: Hotel Management System
Project Overview:
The Hotel Management System (HMS) project is designed to streamline and
automate various operations involved in managing a hotel. The system aims
to enhance efficiency, accuracy, and user experience by integrating key
functionalities needed for effective hotel management.
Objectives:
1. Reservation Management: Simplify the process of booking and
managing room reservations. This includes checking room availability,
making new bookings, modifying existing reservations, and canceling
bookings.
2. Guest Management: Maintain a comprehensive database of guest
information, including personal details, booking history, and special
requests. This feature aims to improve guest relations and service
quality.
3. Room Management: Track room statuses, manage room assignments,
and update room availability in real-time. This helps in optimizing room
usage and ensuring that guests have accurate information about room
availability.
4. Billing and Invoicing: Automate the billing process by generating
accurate invoices, tracking payments, and managing various payment
methods. This feature aims to reduce manual errors and speed up the
checkout process.
5. Reporting and Analytics: Provide detailed reports on various aspects of
hotel operations, such as occupancy rates, revenue, and guest
demographics. These insights are crucial for making informed business
decisions and improving overall hotel performance.
CODEBASE
# Global variables
room_no_count = 0
rooms = []
def welcome_message():
print("\n*****WELCOME TO ABC HOTEL*****\n")
def get_next_room_no():
global room_no_count
room_no_count += 1
return room_no_count
def enter_customer_data():
global rooms
room_no = get_next_room_no()
rooms.append({
"room_no": room_no,
"name": name,
"address": address,
"cindate": cindate,
"coutdate": coutdate,
"s": 0,
"r": 0,
"t": 0,
"p": 0,
"a": 1800
})
print(f"Your room no.: {room_no}\n")
def calculate_room_rent(room_no):
room_rents = {1: 6000, 2: 5000, 3: 4000, 4: 3000}
print("We have the following rooms for you:-")
for key, value in room_rents.items():
print(f"{key}. type {chr(64 + key)}---->rs {value} PN\-")
if x in room_rents:
rent = room_rents[x] * n
for room in rooms:
if room["room_no"] == room_no:
room["s"] = rent
print(f"You have opted room type {chr(64 + x)}")
print(f"Your room rent is = Rs {rent}\n")
else:
print("Please choose a valid room type.")
def calculate_restaurant_bill(room_no):
restaurant_menu = {1: 20, 2: 10, 3: 90, 4: 110, 5: 150}
print("\n*****RESTAURANT MENU*****\n")
total = 0
while True:
c = int(input("Enter your choice:"))
if c in restaurant_menu:
d = int(input("Enter the quantity:"))
total += restaurant_menu[c] * d
elif c==6:
break
else:
print("Invalid option")
total = 0
while True:
e = int(input("Enter your choice:"))
if e in laundry_menu:
elif e==6:
break
else:
print("Invalid option")
total = 0
while True:
g = int(input("Enter your choice:"))
if g in game_menu:
h = int(input("No. of hours:"))
total += game_menu[g] * h
elif g == 6:
break
else:
print("Invalid option")
def show_rooms_booked():
if rooms:
print(rooms)
else:
print("All rooms available")
def main():
welcome_message()
while True:
print("1. Enter Customer Data")
print("2. Calculate Room Rent")
print("3. Calculate Restaurant Bill")
print("4. Calculate Laundry Bill")
print("5. Calculate Game Bill")
print("6. Show Total Cost")
print("7. Rooms Booked")
print("8. EXIT")
print()
try:
choice = int(input("Enter your choice: "))
if choice == 1:
enter_customer_data()
elif choice == 2:
room_no = int(input("Enter room number: "))
calculate_room_rent(room_no)
elif choice == 3:
room_no = int(input("Enter room number: "))
calculate_restaurant_bill(room_no)
elif choice == 4:
room_no = int(input("Enter room number: "))
calculate_laundry_bill(room_no)
elif choice == 5:
room_no = int(input("Enter room number: "))
calculate_game_bill(room_no)
elif choice == 6:
room_no = int(input("Enter room number: "))
display_bill(room_no)
elif choice == 7:
show_rooms_booked()
elif choice == 8:
break
else:
print("Invalid choice, please try again.")
except Exception as e: # catch errors
print(f"{e} ---> INVALID INPUT! \n")
if __name__ == "__main__":
main()
WORKING
BIBLIOGRAPHY