Suryansh and Vivek Comp
Suryansh and Vivek Comp
Submitted To Submitted By
Mr. Ankit Saxena SURYANSH TIWARI
Class : XII
CERTIFICATE
CLASS: XII
I would like to convey by heartfelt thanks to Mr. Ankit
Saxena my computer teacher who always gave valuable
suggestion and guidance for completion of my project.
He helped me to understand important details of the
project that I would have otherwise loss.
My project has only been success because of his
guidance. I am also very thankful to our honourable
principal Mr. Hariom Singh for the encouragement and
support he imparted to me in setting the forth project.
Student Name :
SURY ANSH TIWARI
Class:XII
1- Project Introduction
2- Imported Files & Used Functions in Python
3- Introduction about database & Tables
4- Coding of the Project
5- Output
6- Requirement of hardware and Software
7- Limitations
8- Bibliography
FLIGHT
MANAGEMENT
SYSTEM
Project Introduction
Functions:-
Pre-Defined Functions :
Tables:-
1-PASSDATA
2-TKT
Project Code
def registerpass():
cur.execute("insert into
passdata(passno,name,addr,jrdate,source,dest)values('%d','%s','%s','%s',
'%s','%s')"%(passno,name,addr,jrdate,source,dest))
ob.commit()
def search():
fa=cur.fetchall()
print(row)
'''for a in cur:
print(passno,"\t",name,"\t",addr,"\t",jrdate,"\t",source,"\t",dest)'''
ob.commit()
def dispall():
fa=cur.fetchall()
ob.commit()
k=(['passno','name','addr','jrdate','source','dest'])
print(passno,"\t",name,"\t",addr,"\t",jrdate,"\t",source,"\t",dest)
ob.commit()
def ticketprice():
if x==1:
elif x==2:
s=3000*n
elif x==3:
s=5000*n
else:
z=y*100
g_tot=s+z
cur.execute("insert into
tkt(passno,Ticket_fare,Luggage_fare,Total_fare)values('%d','%d','%d','
%d')"%(cno,s,z,g_tot))
ob.commit()
def cancel():
def update():
ob.commit()
print("🎀________________________________HI______________________
___________________🎀")
print("❁•❁•❁•❁•❁•❁•❁❁•❁•❁•❁•❁•❁•❁❁•❁•❁•❁•❁•❁•❁•❁•❁•❁•❁❁•❁•❁•❁•
❁•❁")
print("⋆。‧˚ʚ♡ɞ˚‧。⋆⋆。‧˚ʚ♡ɞ˚‧。⋆⋆。‧˚ʚ♡ɞ˚‧。⋆⋆。‧˚ʚ♡ɞ˚‧。⋆⋆。‧˚ʚ♡ɞ˚‧。⋆⋆。‧˚ʚ♡ɞ˚‧。⋆⋆
。‧˚ʚ♡ɞ˚‧。⋆⋆。‧˚ʚ♡ɞ˚‧")
import mysql.connector as co
ob=co.connect(host="localhost",user="root",password="1234")
cur=ob.cursor()
cur.execute("use Roadways")
ob.commit()
while True:
print("Enter 7 :- EXIT")
if ch==1:
registerpass()
elif ch==2:
ticketprice()
elif ch==3:
search()
elif ch==4:
dispall()
elif ch==5:
cancel()
elif ch==6:
update()
elif ch==7:
break;
else:
Output
Requirement of hardware and Software
Hardware :
1- Processor : Pentium ® G2030@ 3.70 GHz
2- RAM : 4 GB
3- System Architecture : 64 bits Operating System
4- HDD – 500 GB
Software :
1- Operating System : Window 8.1
2- IDE: IDLE Python
3- MySql
1- Printing Facility is not available.
1. python.org
2. Code Academy
3.tutorialsPoint.com
4. PythonChallenge.com
5. Google’s Python Class
6. LearnPython.org