IP Project XII Final PDF
IP Project XII Final PDF
CLASS : XII–‘C’
SUBCODE : 083
1
ACKNOWLEDGEMENT
Apart from the efforts of me, the success of any project depends largely on the
encouragement and guidelines of many others. I take this opportunity to express my
gratitude to the people who have been instrumental in the successful completion of
this project.
I express deep sense of gratitude to almighty God for giving me strength for the
successful completion of the project.
I express my heartfelt gratitude to my parents for constant encouragement while
carrying out this project.
I gratefully acknowledge the contribution of the individuals who contributed in
bringing this project up to this level, who continues to look after me despite my
flaws, I express my deep sense of gratitude to the luminary The Principal, Vallaba
Vidyalaya who has been continuously motivating and extending their helping hand
to us.
My sincere thanks to Mrs. Madheena Banu subject In-charge, A guide, Mentor all
the above a friend, who critically reviewed my project and helped in solving each
and every problem, occurred during implementation of the project.
The guidance and support received from all the members who contributed and who
are contributing to this project, was vital for the success of the project. I am grateful
for their constant support and help.
2
TABLE OF CONTENTS
01 PROJECT SYNOPSIS 04
02 PYTHON HISTORY 07
03 PROPOSED SYSTEM 08
04 NUMPY 09
05 MATPLOT 10
06 PANDAS 10
07 SOURCE CODE 11
08 OUTPUT 23
09 BIBLIOGRAPHY 28
3
PROJECT SYNOPSIS
Problem Definition:
Design a Project to collect data from the user and help them book movie
tickets .Satisfactory, preciseness and instant output are the key motto.
Team Detail:
4
Reason for choosing the Topic:
We took this topic because India’s film industry ranks among the top 10 film
industries in the world. Movies are one of the source for entertainment. New
movies are always coming up and it is welcomed by the people and there is a
huge fan base for it. There is always a huge queue in front of the ticket counter
for reservation of ticket. That's why we decided to design and develop a python
based computerized Movie Ticket Reservation system . By using this user can
book tickets without standing in a long queue. This would simplify a big task,
could replace manual work and can minimize the burden. We took the
challenge and started working with this project to automate the job using
Python programming
5
Objective:
The main aim of this Movie World is booking online tickets for various movies
in Registered theatres by the users.
Hardware Requirements:
Software Requirements
Python:3.6.x or higher version:
a. numpy library
b. matplot library
c. pandas
6
PYTHON HISTORY:
Python is a high-level, general-purpose programming language. Its design philosophy
emphasizes code readability with the use of significant indentation.
Guido van Rossum began working on Python in the late 1980s as a successor to the ABC
programming language and first released it in 1991 as Python 0.9.0. Python 2.0 was
released in 2000 and introduced new features such as list comprehensions, cycle-
detecting garbage collection, reference counting, and Unicode support. Python 3.0, released in
2008, was a major revision that is not completely backward-compatible with earlier versions.
Python 2 was discontinued with version 2.7.18 in 2020.
Guido van Rossum began working on Python in the late 1980s as a successor to the ABC
programming language and first released it in 1991 as Python 0.9.0. Python 2.0 was
released in 2000 and introduced new features such as list comprehensions, cycle-
detecting garbage collection, reference counting, and Unicode support. Python 3.0, released in
2008, was a major revision that is not completely backward-compatible with earlier versions.
Python 2 was discontinued with version 2.7.18 in 2020.
7
PROPOSED SYSTEM:
1. USER
2. ADMIN
USER:
The user can first register their details and choose the movie they want and book movie
tickets. In addition, they can also buy their preferred snacks. And, finally the ticket is
generated with the total amount calculated.
ADMIN:
The admin can also book tickets and she/he can also preview the survey graphs.
The following are the graphs that will be generated.
1. Bar graph for revenue earned in a day.
2. Bar graph for revenue earned in a specific time.
3. Bar graph for name vs amount paid.
4. Pie chart for individual payment.
5. Pie chart for revenue earned in a day.
8
NUMPY:
NumPy is a library for the Python programming language, adding support for large, multi-
dimensional arrays and matrices, along with a large collection of high-
level mathematical functions to operate on these arrays
The Python programming language was not originally designed for numerical computing,
but attracted the attention of the scientific and engineering community early on. In 1995
the special interest group (SIG) matrix-sig was founded with the aim of defining
an array computing package; among its members was Python designer and
maintainer Guido van Rossum, who extended Python's syntax (in particular the indexing
syntax) to make array computing easier.
An implementation of a matrix package was completed by Jim Fulton, then
generalized[further explanation needed] by Jim Hugunin and called Numeric (also
variously known as the "Numerical Python extensions" or "NumPy"). Hugunin, a graduate
student at the Massachusetts Institute of Technology (MIT),: 10 joined the Corporation for
National Research Initiatives (CNRI) in 1997 to work on JPython, leaving Paul Dubois
of Lawrence Livermore National Laboratory (LLNL) to take over as maintainer.: 10 Other
early contributors include David Ascher, Konrad Hinsen and Travis Oliphant.: 10
A new package called Numarray was written as a more flexible replacement for
Numeric. Like Numeric, it too is now deprecated. Numarray had faster operations for large
arrays, but was slower than Numeric on small ones, so for a time both packages were used
in parallel for different use cases. The last version of Numeric (v24.2) was released on 11
November 2005, while the last version of numarray (v1.5.2) was released on 24 August
2006.
There was a desire to get Numeric into the Python standard library, but Guido van Rossum
decided that the code was not maintainable in its state then.[when?]
In early 2005, NumPy developer Travis Oliphant wanted to unify the community around a
single array package and ported Numarray's features to Numeric, releasing the result as
NumPy 1.0 in 2006. This new project was part of SciPy. To avoid installing the large SciPy
9
package just to get an array object, this new package was separated and called NumPy.
Support for Python 3 was added in 2011 with NumPy version 1.5.0.
In 2011, PyPy started development on an implementation of the NumPy API for PyPy. It is
not yet fully compatible with NumPy.
MATPLOT:
Matplotlib is a plotting library for the Python programming language and its numerical
mathematics extension NumPy. It provides an object-oriented API for embedding plots into
applications using general-purpose GUI toolkits like Tkinter, wxPython, Qt, or GTK. There is
also a procedural "pylab" interface based on a state machine (like OpenGL), designed to
closely resemble that of MATLAB, though its use is discouraged. SciPy makes use of
Matplotlib.
Matplotlib was originally written by John D. Hunter. Since then it has had an active
development community and is distributed under a BSD-style license. Michael Droettboom
was nominated as matplotlib's lead developer shortly before John Hunter's death in August
2012 and was further joined by Thomas Caswell. Matplotlib is a NumFOCUS fiscally
sponsored project.
Matplotlib 2.0.x supports Python versions 2.7 through 3.10. Python 3 support started with
Matplotlib 1.2. Matplotlib 1.4 is the last version to support Python 2.6. Matplotlib has
pledged not to support Python 2 past 2020 by signing the Python 3 Statement.
PANDAS:
Pandas is a software library written for the Python programming language for data
manipulation and analysis. In particular, it offers data structures and operations for
manipulating numerical tables and time series. It is free software released under the three-
clause BSD license. The name is derived from the term "panel data", an econometrics term
for data sets that include observations over multiple time periods for the same
10
individuals. Its name is a play on the phrase "Python data analysis" itself. Wes
McKinney started building what would become pandas at AQR Capital while he was a
researcher there from 2007 to 2010.
CODE:
import numpy as np
import pandas as pd
12
master_seats_list = []
name_details = []
movie_details = []
date_details = []
time_details = []
cost_details = []
13
# Selecting a movie
while True:
try:
movie_number = int(input("Enter movie no: "))
if movie_number == 1:
name_of_movie = 'Fight Club'
elif movie_number == 2:
name_of_movie = 'Inception'
elif movie_number == 3:
name_of_movie = 'Se7en'
elif movie_number == 4:
name_of_movie = 'Prisoners'
elif movie_number == 5:
name_of_movie = 'Exhuma'
else:
print('\nInvalid response. Please choose a number from the given list.')
continue
movie_details.append(name_of_movie)
break
except ValueError:
print('\nInvalid response. Please enter a valid number.’)
# Selecting date
while True:
print('\nAvailable Dates: ')
14
print('1 - 01-05-2024')
print('2 - 02-05-2024')
print('3 - 03-05-2024')
print('4 - 04-05-2024')
date_number = input("Enter date (choose from 1-4): ")
if date_number in ['1', '2', '3', '4']:
date_details.append(f"{date_number}-05-2024")
break
else:
print('\nInvalid response. Please choose a number from the given list.')
# Selecting time
while True:
print('\nAvailable Timings: ')
print('1 - 01:00')
print('2 - 02:00')
print('3 - 03:00')
print('4 - 04:00')
print('5 - 05:00')
time_number = input("Enter time (choose from 1-5): ")
if time_number in ['1', '2', '3', '4', '5']:
time_details.append(f"{time_number}:00")
break
else:
print('\nInvalid response. Please choose a number from the given list.’)
15
print("\nPlease select your seats:")
seats_printing()
17
snack_list.append('Icecream')
break
elif snacks_number == '3':
cost_of_snacks += 350
snack_list.append('Chicken Nuggets')
break
elif snacks_number == '4':
cost_of_snacks += 150
snack_list.append('Soft Drinks')
break
elif snacks_number == '5':
cost_of_snacks += 80
snack_list.append('Puffs')
break
else:
print('\nInvalid input. Please choose a number from the given list.')
break
elif snack_value == '2':
break
else:
print('\nInvalid input. Please enter 1 for snacks or 2 for no snacks.’)
# Calculate total cost of ticket
cost_of_ticket = cost_of_seats + cost_of_snacks
cost_details.append(cost_of_ticket)
# Display ticket details
print("\nYOUR TICKET:")
print(f"| MOVIE : {name_of_movie} |")
print(f"| NAME : {name} |")
18
print(f"| DATE : {date_details[-1]} |")
print(f"| TIME : {time_details[-1]} |")
print(f"| SEATS : {' '.join(seats_list)} |")
print(f"| AMOUNT : {cost_of_ticket} |")
20
plt.ylabel('Revenue')
plt.title('Revenue earned at specific times’)
elif graph_settings == '3':
plt.plot(name_details, cost_details)
plt.xlabel('Customer Name')
plt.ylabel('Amount Paid')
plt.title('Amount paid by each customer')
plt.show()
elif graph_settings == '4':
plt.bar(date_details, cost_details)
plt.xlabel('Date')
plt.ylabel('Revenue')
plt.title('Revenue earned in a day')
plt.xticks(rotation=45)
plt.tight_layout()
plt.show()
elif graph_settings == '5':
plt.bar(time_details, cost_details)
plt.xlabel('Time’)
plt.ylabel('Revenue')
plt.title('Revenue earned at specific times')
plt.xticks(rotation=45)
plt.tight_layout()
plt.show()
elif graph_settings == '6':
plt.bar(name_details, cost_details)
plt.xlabel('Customer Name')
plt.ylabel('Amount Paid')
21
plt.title('Amount paid by each customer')
plt.xticks(rotation=45)
plt.tight_layout()
plt.show()
elif graph_settings == '7':
break
else:
print('\nInvalid input. Please enter a number from 1 to 7.')
22
OUTPUT:
.
For admin, he/she can book tickets and also generate graphs.
23
This is the seating arrangement of the theatre.
24
2. Line graph for revenue earned in a specific time.
25
4 . Bar graph for revenue earned in a day.
26
6 . Bar graph for name vs amount he paid.
27
BIBLIOGRAPHY/REFERENCE:
28