Sample_project_cs
Sample_project_cs
PROGRAMMIN
COMPUTER – Lakshya
Kumar
SCIENCE PROJECT CLASS XII-D
FILE 2020-21
PYTHON
KENDRIYA VIDALAYA BHARATPUR ( RAJ.)
JAIPUR REGION (13)
Submitted by :- Submitted To :-
_________________ _________________
Examiner’s Signature Sub. Teacher’s Signature
______________ _________________
Date of checking Principal’s Signature
_______________
School Rubber Stamp
ACKNOWLEDGEMENT
Thank you
LAKSHYA KUMAR
XII-D (MATHS-SCIENCE)
Roll-no :22
OVERVIEW OF PYTHOn SOFTWARE
group works.
Processors:
Disk Space -: 2 to 3 GB
Processors:
SOFTWARE:
PIP & NUMPY -: Installing with pip, ubuntu*,python 3.8.2
*******************************************************************************
NAME OF FILE :- DATABASE OF KVS-SCHOOLS
*******************************************************************************
MYSQL –DATABASE VEIW
DATA-BASE NAME :-
elif ch==2:
kc=int(input("Enter the KV_CODE : "))
N=65
mysql="select * from kv_data_2020 where kv_code={}".format(kc)
print(mysql)
myc.execute(mysql) #this command excute the mysql
myresult=myc.fetchall() #this command take all the data from mysql data bases
print("================== KVS NAME ==================================\n")
for rec in myresult:
print("KV Name \t\t\t:",rec[9].upper())
print("KV_Code \t\t\t:",rec[8])
print("Zone_of_KV \t\t:",rec[2].upper())
print("Region_of_KV \t\t:",rec[4].upper())
print('='*N,'\n')
print(myc.rowcount," : kvs found in the kvs_database\n\n ")
elif ch==3:
cit=input("Enter the city/state of the kv to find : ")
N=65
mysql="select * from kv_data_2020 where station_name ='{}'".format(cit)
#print(mysql)
myc.execute(mysql) #this command excute the mysql
myresult=myc.fetchall() #this command take all the data from mysql data bases
print("================== KVS NAME ==================================\n")
elif ch==4:
a=True
while a:
print("1. Count the kvs zone_wise")
print("2. Count the kvs Region_wise")
print("3. Exit in the option ")
ch=int(input("Enter your choice :"))
if ch==1:
N=60
mysql="select distinct zone_code,left(zone_name,12),count(kv_code) from kv_data_2020
group by zone_name order by zone_code"
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome Zone Department of KVS ======================")
print("zone_code\tZone_name\t\tNo of kvs")
for rec in myresult:
print(rec[0],"\t\t",rec[1],"\t\t",rec[2])
print("="*N)
print(myc.rowcount," : kvs found in the database\n ")
elif ch==3:
a=False
break
print("you are exit in the option ")
else :
print("Please enterd the valid choice ")
def show_zone():
N=60
mysql="select distinct zone_code,zone_name from kv_data_2020"
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome Zone Department of KVS ======================")
print("zone_code\tZone_name\n")
for rec in myresult:
print(rec[0],"\t\t",rec[1])
print("="*N)
print(myc.rowcount," : zone found in the database\n ")
a=True
while a:
print("1. Show all KVS_regions by zone_wise")
print("2. Search the KVS_regions by zone_wise")
print("3. Search the kv by Zone_Code ")
print("4. Search the kv by Zone_Name ")
print("5. Search the name of region by zone_code ")
print("6. Exit in the option \n")
ch=int(input("Enter your choice : "))
if ch==1:
N=60
mysql="select distinct zone_code,left(zone_name,11),region_name from kv_data_2020"
myc.execute(mysql)
myresult=myc.fetchall()
print("zone_code\tZone_name\t\tRegion_name ")
print("="*N)
for rec in myresult:
print(rec[0],'\t\t',rec[1],'\t\t',rec[2])
print("="*N)
print(myc.rowcount," : region found by zone wise \n\n")
elif ch==2:
N=60
kr=input("Enter the name of kvs_region to find : " )
mysql="select distinct zone_code,zone_name,region_name from kv_data_2020 where
region_name='{}'".format(kr)
myc.execute(mysql)
myresult=myc.fetchall()
#print("zone_code\tZone_name\t\tRegion_name \n")
print("============================================================")
for rec in myresult:
#print(rec[0],'\t\t',rec[1],'\t\t',rec[2])
print("Zone_code \t\t\t:",rec[0])
print("Zone_Name \t\t\t:",rec[1])
print("Region_Name \t\t\t:",rec[2])
print("="*N)
print(myc.rowcount," : region found by zone wise \n\n")
elif ch==3:
kz=int(input("Enter the Zone_code of the kv : "))
N=65
mysql="select zone_code,zone_name,region_name,kv_code,kv_name from kv_data_2020 where
Zone_code={}".format(kz)
print(mysql)
myc.execute(mysql) #this command excute the mysql
myresult=myc.fetchall() #this command take all the data from mysql data bases
print("====================== KVS NAME ===========================")
#print('Name\t\tZone_name\tZone_code\tRegion_name\tkv_code')
#print('='*N)
for rec in myresult:
#print("the zone of kv is ",rec[2].upper())
#print(rec[9]),'\t',rec[2],'\t',rec[1],'\t',rec[4],'\t\t',rec[8])
print("Zone_code \t\t\t:",rec[0])
print("Zone_Name \t\t\t:",rec[1])
print("Region_name \t\t\t:",rec[2])
print("KV_code \t\t\t\t:",rec[3])
print("KV_name \t\t\t:",rec[4])
print('='*N)
print(myc.rowcount," : KVS_schools found in the table\n\n ")
elif ch==4:
kzn=input("Enter the kv_school Zone_name : " )
N=65
mysql="select zone_code,zone_name,region_code,region_name,kv_code,kv_name from
kv_data_2020 where Zone_name='{}'".format(kzn)
print(mysql)
myc.execute(mysql) #this command excute the mysql
myresult=myc.fetchall() #this command take all the data from mysql data bases
print("===================== KVS NAME ===========================")
#print('Name\t\tZone_name\tRegion_name\tkv_code')
print('='*N)
for rec in myresult:
#print("the zone of kv is ",rec[2].upper())
#print(rec[9],'\t',rec[2],'\t',rec[4],'\t\t',rec[8])
print("Zone_code \t\t\t:",rec[0])
print("Zone_Name \t\t\t:",rec[1])
print("Region_code \t\t\t:",rec[2])
print("Region_name \t\t\t:",rec[3])
print("KV_code \t\t\t\t:",rec[4])
print("KV_name \t\t\t:",rec[5])
print('='*N)
print(myc.rowcount," : KVS school found in the table\n\n ")
elif ch==5:
kzc=int(input("Enter the zone code of kv : " ))
N=65
mysql="select distinct zone_code,zone_name,region_code,region_name from kv_data_2020
where zone_code={}".format(kzc)
print(mysql)
myc.execute(mysql) #this command excute the mysql
myresult=myc.fetchall() #this command take all the data from mysql data bases
print("===================== KVS NAME ===========================")
print('Zone_code\tZone_name\t\tRegion_code\tRegion_name')
print('='*N)
for rec in myresult:
#print("the zone of kv is ",rec[1].upper())
print(rec[0],'\t\t',rec[1],'\t\t',rec[2],'\t\t',rec[3])
print('='*N)
print(myc.rowcount," : KVS Regions found in the table\n\n ")
elif ch==6:
a=False
break
print("You are exit in the program ")
else :
print("!!! please Enterd the valid choice !!! ")
def show_region():
N=50
mysql="select distinct region_code,region_name from kv_data_2020 group by region_code"
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome Regions Department of KVS ======================")
print("Region_code\tRegion_name")
print("="*N)
for rec in myresult:
print(rec[0],"\t\t",rec[1])
print("="*N)
print(myc.rowcount," : Regions found in the database\n ")
a=True
while a:
print("1. Show all KVS_regions by zone_wise")
print("2. Search the KVS_zones by Region_wise")
print("3. Search the name of Zone by region_code ")
print("4. Search the kv by Region_Code ")
print("5. Search the kv by Region_Name ")
print("6. Exit in the option \n")
ch=int(input("Enter your choice : "))
if ch==1:
N=60
mysql="select distinct zone_code,(zone_name,11),region_code,region_name from kv_data_2020
group by region_code"
myc.execute(mysql)
myresult=myc.fetchall()
print("zone_code\tZone_name\tRegion_name ")
for rec in myresult:
print(rec[0],'\t\t',rec[1],'\t\t',rec[2],'\t\t',rec[3])
print("="*N)
print(myc.rowcount," : region found by zone wise \n\n")
elif ch==2:
N=60
kr=input("Enter the name of kvs_zone to find : " )
mysql="select distinct zone_code,zone_name,region_name from kv_data_2020 where
zone_name='{}'".format(kr)
myc.execute(mysql)
myresult=myc.fetchall()
print("zone_code\tZone_name\t\tRegion_name \n")
print("============================================================")
for rec in myresult:
print(rec[0],'\t\t',rec[1],'\t\t',rec[2])
print("="*N)
print(myc.rowcount," : region found by zone wise \n\n")
elif ch==3:
kzc=int(input("Enter the region_code of kv : " ))
N=65
mysql="select distinct zone_code,zone_name,region_code,region_name from kv_data_2020
where region_code={}".format(kzc)
print(mysql)
myc.execute(mysql) #this command excute the mysql
myresult=myc.fetchall() #this command take all the data from mysql data bases
print("===================== KVS NAME ===========================")
print('Zone_code\tZone_name\t\tRegion_code\tRegion_name')
print('='*N)
for rec in myresult:
#print("the zone of kv is ",rec[1].upper())
print(rec[0],'\t\t',rec[1],'\t\t',rec[2],'\t\t',rec[3])
print('='*N)
print(myc.rowcount," : KVS Regions found in the table\n\n ")
elif ch==5:
kr=input("Enter the kv region_name : ")
N=65
mysql="select region_code,region_name,zone_code,zone_name,kv_code,kv_name from
kv_data_2020 where Region_name='{}'".format(kr)
#print(mysql)
myc.execute(mysql) #this command excute the mysql
myresult=myc.fetchall() #this command take all the data from mysql data bases
print("==================== KVS NAME ==============================")
print('Name\t\t\tZone_name\t\tRegion_name\t\tkv_code')
print('='*N)
for rec in myresult:
#print(rec[9],'\t\t',rec[2],'\t\t',rec[4],'\t\t\t',rec[8])
print("The Region-code \t\t\t:",rec[0])
print("The Region-Name \t\t\t:",rec[1])
print("The Zone-code \t\t\t:",rec[2])
print("The Zone-Name \t\t\t:", rec[3])
print("The KV-Code \t\t\t:",rec[4])
print("The KV-Name \t\t\t:",rec[5])
print('='*N)
print(myc.rowcount," : kvs schools are found in the",rec[1].upper(),"\n\n ")
elif ch==4:
krc=int(input("Enter the Region_code of the kv " ))
N=65
mysql="select region_code,region_name,zone_code,zone_name,kv_code,kv_name from
kv_data_2020 where Region_code={}".format(krc)
#print(mysql)
myc.execute(mysql) #this command excute the mysql
myresult=myc.fetchall() #this command take all the data from mysql data bases
print("================== KVS NAME ===============================")
#print('Name\t\tZone_name\tRegion_name\tkv_code')
print('='*N)
for rec in myresult:
#print('THE REGION IS ',rec[4].upper())
#print(rec[9],'\t5',rec[2],'\t',rec[4],'\t\t',rec[8])
print("The Region-code \t\t\t:",rec[0])
print("The Region-Name \t\t\t:",rec[1])
print("The Zone-code \t\t\t:",rec[2])
print("The Zone-Name \t\t\t:", rec[3])
print("The KV-Code \t\t\t:",rec[4])
print("The KV-Name \t\t\t:",rec[5])
print('='*N)
print(myc.rowcount," : kvs schools are found in the",rec[1].upper(),"\n\n ")
elif ch==6:
a=False
break
print("You are exit in the program ")
else :
print("!!! please Enterd the valid choice !!! ")
def show_ziet():
N=60
mysql="select zone_code,zone_name,kv_code,kv_name from kv_data_2020 where region_name like
'%ziet%'"
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome To ZIET Department ==========================")
print("===============ZONEAL-INSTIUTE-EDUCATION-TRANING======================")
print("="*N,'\n')
for rec in myresult:
#print(rec[1],'\t',rec[2],'\t',rec[3],'\t',rec[4],'\t',rec[8],'\t',rec[9])
print("The Zone-code \t\t\t:",rec[0])
print("The Zone-Name \t\t\t:",rec[1])
print("The ZIET-code \t\t\t:",rec[2])
print("The ZIET-Name \t\t\t:",rec[3])
print('='*N,'\n')
print(myc.rowcount," : ZIET found in kvs databases ")
def show_crpf():
N=60
mysql="select * from kv_data_2020 where kv_name like '%crpf%'"
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome To CF Department ==========================")
print("ZC\t\tZN\tRC\t\tRN\t\tKv_code\tKV_NAME")
print("="*N,'\n')
for rec in myresult:
print(rec[1],'\t',rec[2],'\t',rec[3],'\t',rec[4],'\t',rec[8],'\t',rec[9])
print('='*N,'\n')
print(myc.rowcount," : CRPF SCHOOL found in kvs databases ")
def show_iit():
N=60
mysql="select zone_code,zone_name,region_name,region_code,station_name,kv_code,kv_name
from kv_data_2020 where kv_name like '%iit%' group by region_code"
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome To ZIET-IIT Department ==========================\n")
print("===================INDIAN-INSTITUTE-TECHNOLOGY=======================\n")
print("="*N,'\n')
for rec in myresult:
#print(rec[1],'\t',rec[2],'\t',rec[3],'\t',rec[4],'\t',rec[8],'\t',rec[9])
print("The Region-code \t\t\t:",rec[3])
print("The Region-Name \t\t\t:",rec[2])
print("The Zone-code \t\t\t:",rec[0])
print("The Zone-Name \t\t\t:", rec[1])
print("City Name \t\t\t:",rec[4])
print("The KV-IIT-Code \t\t\t:",rec[5])
print("The KV-IIT-Name \t\t\t:",rec[6])
print('='*N,'\n')
print(myc.rowcount," : IIT found in kvs databases ")
def show_cantt():
N=60
mysql="select * from kv_data_2020 where kv_name like '%cantt%'"
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome To CD Department ==========================")
print("ZC\t\tZN\tRC\t\tRN\t\tKv_code\tKV_NAME")
print("="*N,'\n')
for rec in myresult:
print(rec[1],'\t',rec[2],'\t',rec[3],'\t',rec[4],'\t',rec[8],'\t',rec[9])
print('='*N,'\n')
print(myc.rowcount," : Cantt found in kvs databases ")
def show_cant():
N=60
mysql="select * from kv_data_2020 where kv_name like '%cant%'"
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome To CD Department ==========================")
print("ZC\t\tZN\tRC\t\tRN\t\tKv_code\tKV_NAME")
print("="*N,'\n')
for rec in myresult:
print(rec[1],'\t',rec[2],'\t',rec[3],'\t',rec[4],'\t',rec[8],'\t',rec[9])
print('='*N,'\n')
print(myc.rowcount," : Cant found in kvs databases ")
def show_bsf():
N=60
mysql="select * from kv_data_2020 where kv_name like '%bsf%'"
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome To CD Department ==========================")
print("ZC\t\tZN\tRC\t\tRN\t\tKv_code\tKV_NAME")
print("="*N,'\n')
for rec in myresult:
print(rec[1],'\t',rec[2],'\t',rec[3],'\t',rec[4],'\t',rec[8],'\t',rec[9])
print('='*N,'\n')
print(myc.rowcount," : BSF KV_SCHOOLS found in kvs databases ")
def show_oil():
N=60
mysql="select * from kv_data_2020 where kv_name like '%ONGC%' or '%MRP%'"
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome To OIL Department ==========================")
print("ZC\t\tZN\tRC\t\tRN\t\tKv_code\tKV_NAME")
print("="*N,'\n')
for rec in myresult:
print(rec[1],'\t',rec[2],'\t',rec[3],'\t',rec[4],'\t',rec[8],'\t',rec[9])
print('='*N,'\n')
print(myc.rowcount," : OIL FEILDS KV_SCHOOLS found in kvs databases ")
def show_naval():
N=60
mysql="select * from kv_data_2020 where kv_name like '%naval%'"
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome To CD Department ==========================")
print("ZC\t\tZN\tRC\t\tRN\t\tKv_code\tKV_NAME")
print("="*N,'\n')
for rec in myresult:
print(rec[1],'\t',rec[2],'\t',rec[3],'\t',rec[4],'\t',rec[8],'\t',rec[9])
print('='*N,'\n')
print(myc.rowcount," : naval-base found in kvs databases ")
def show_army():
N=60
mysql="select * from kv_data_2020 where kv_name like '%army%'"
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome To CD Department ==========================")
print("ZC\t\tZN\tRC\t\tRN\t\tKv_code\tKV_NAME")
print("="*N,'\n')
for rec in myresult:
print(rec[1],'\t',rec[2],'\t',rec[3],'\t',rec[4],'\t',rec[8],'\t',rec[9])
print('='*N)
print(myc.rowcount," : Army schools found in kvs databases ")
def show_afs():
N=60
mysql="select * from kv_data_2020 where kv_name like '%AFS%'"
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome To CD Department ==========================")
print("ZC\t\tZN\tRC\t\tRN\t\tKv_code\tKV_NAME")
print("="*N,'\n')
for rec in myresult:
print(rec[1],'\t',rec[2],'\t',rec[3],'\t',rec[4],'\t',rec[8],'\t',rec[9])
print('='*N)
print(myc.rowcount," : Air_force_school found in kvs databases ")
def show_rly():
N=60
mysql="select * from kv_data_2020 where kv_name like '%RLY%'"
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome To railway region Department
==========================")
print("ZC\t\tZN\tRC\t\tRN\t\tKv_code\tKV_NAME")
print("="*N,'\n')
for rec in myresult:
print(rec[1],'\t',rec[2],'\t',rec[3],'\t',rec[4],'\t',rec[8],'\t',rec[9])
print('='*N)
print(myc.rowcount," : railway_region_school found in kvs databases ")
def show_ro():
a=True
while a:
print("=============== Welcome To Regional-Office Dep. of KVS ====================")
print("1. Show all the Regional-office of kvs ")
print("2. search the Regional-office of kvs ")
print("3. Search the Regional-office by Zone_Wise ")
print("4. Exit in option ")
ch=int(input("Enter the choice : "))
if ch==1:
N=60
mysql="select * from kv_data_2020 where kv_name like '%R O%'"
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome To RO Department ==========================")
print("ZC\t\tZN\tRC\t\tRN\t\tKv_code\tRO_NAME")
print("="*N,'\n')
for rec in myresult:
print(rec[1],'\t',rec[2],'\t',rec[3],'\t',rec[4],'\t',rec[8],'\t',rec[9])
print('='*N,'\n')
print(myc.rowcount," : Regional offices found in kvs databases ")
elif ch==2:
N=60
print("Enter like : R O Jaipur \n")
print("Please use caps_lock button \n")
ro=input("Enter the name of the ro kvs ")
mysql="select * from kv_data_2020 where kv_name = '{}'".format(ro)
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome To RO Department ==========================")
print("ZC\t\tZN\tRC\t\tRN\t\tKv_code\tRO_NAME")
print("="*N,'\n')
for rec in myresult:
print(rec[1],'\t',rec[2],'\t',rec[3],'\t',rec[4],'\t',rec[8],'\t',rec[9])
print('='*N,'\n')
print(myc.rowcount," : Regional office found in kvs databases ")
elif ch==3:
N=50
mysql="select distinct zone_code,zone_name from kv_data_2020"
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome Zone Department of KVS ======================")
print("zone_code\tZone_name\n")
for rec in myresult:
print(rec[0],"\t\t",rec[1])
print("="*N)
print(myc.rowcount," : zone found in the database\n ")
N=50
zc=int(input('Enter the code of zone : '))
mysql="select * from kv_data_2020 where kv_name like '%R O%' and zone_code = {}".format(zc)
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome To RO Department ==========================")
print("ZC\t\tZN\tRC\t\tRN\t\tKv_code\tRO_NAME")
print("="*N,'\n')
for rec in myresult:
print(rec[1],'\t',rec[2],'\t',rec[3],'\t',rec[4],'\t',rec[8],'\t',rec[9])
print('='*N,'\n')
print(myc.rowcount," : Regional office found in kvs databases ")
elif ch==4:
a=False
break
else :
print("please enterd the valid choice ")
def show_levl():
print("===================== Welcome to Statation_type ================" )
print("H= HARD STATION ")
print("V= VERY HARD STATION ")
print("NER = NORTH-EAST REGION ")
print("=======================================================")
a=True
while a:
print("1. Search the kv by hq/NER/V")
print("2. Search the kv by H/V/NER by region_wise ")
print("3. Search the kv by H/V/NER BY ZONE_WISE ")
print("4. Exit in the option\n ")
ch=int(input("Enter the choice : "))
if ch==2:
N=50
mysql="select distinct region_code,region_name from kv_data_2020 group by region_code"
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome Regions Department of KVS ======================")
print("Region_code\tRegion_name\n")
for rec in myresult:
print(rec[0],"\t\t",rec[1])
print("="*N)
print(myc.rowcount," : Regions found in the database\n ")
elif ch==1:
lev=input("Enter the level of kv : ")
#reg=input("Enter the region of kv : ")
N=65
mysql="select * from kv_data_2020 where station_type='{}' ".format(lev)
#print(mysql)
myc.execute(mysql) #this command excute the mysql
myresult=myc.fetchall() #this command take all the data from mysql data bases
print("================== KVS NAME ===============================")
print('Name\t\tZone_name\tRegion_name\tkv_code')
print('='*N)
for rec in myresult:
print('THE REGION IS ',rec[4].upper())
print(rec[9],'\t5',rec[2],'\t',rec[4],'\t\t',rec[8])
print('='*N)
print(myc.rowcount," : rows found in the table\n\n ")
elif ch==3:
N=50
mysql="select distinct zone_code,zone_name from kv_data_2020 "
myc.execute(mysql)
myresult=myc.fetchall()
print("================= Welcome Zone Department of KVS ======================")
print("zone_code\tZone_name\n")
for rec in myresult:
print(rec[0],"\t\t",rec[1])
print("="*N)
print(myc.rowcount," : zone found in the database\n ")
def main():
a=True
while a:
print("===================== Welcome To KVS Database ========================\n")
print("1. Search the kv ")
print("2. Search the kv in Region table and Region_Wise ")
print("3. Search the kv in Zone table and Zone_Wise ")
print("4. Search the kv in station table and Station_Wise ")
print("5. Types of KVS ")
print("6. Regional-offices of KVS ")
print("7. Exit the program \n")
print("===============================================================")
ch=int(input("Enter the choice of user "))
if ch==1:
search_kv()
elif ch==2:
show_region()
elif ch==3:
show_zone()
elif ch==4:
show_levl()
elif ch==5:
b=True
while b:
print('==================== Type of kvs =============================\n')
print("1. No of kvs in ZIET ")
print("2. No of KVS in IIT-COLLEGE ")
print("3. No of KVS in BSF AREA ")
print("4. No of KVS in NAVY DEFFENCE ")
print("5. No of KVS in ARMY AREA ")
print("6. No of KVS in AIR_FORCE AREA(AFS)")
print("7. No of KVS in central-army area ")
print("8. No of KVS in CANT. OR CRPF AREA")
print("9. No of KVS under Railway depart. ")
print("10. No of KVS under OIL REFINARY ")
print("11. Exit in the option\n ")
ch=int(input("Enter the choice : "))
if ch==1:
show_ziet()
elif ch==2:
show_iit()
elif ch==7:
show_cantt()
elif ch==3:
show_bsf()
elif ch==4:
show_naval()
elif ch==5:
show_army()
elif ch==6:
show_afs()
elif ch==8:
show_cant()
show_crpf()
elif ch==9:
show_rly()
elif ch==10:
show_oil()
elif ch==11:
b=False
break
print("you are exit in the program ")
else :
print("Please ented the valid choice ")
elif ch==7:
b=False
break
print("You are Exit in the kvs databases ")
elif ch==6:
show_ro()
else:
print("!!! please Enterd the valid choice !!!")
_____________________________________________________________________
#calling the main-prog
if __name__=='__main__':
main()
OUTPUT OF THE PROGRAM
When user entered option 1 -:
= RESTART: D:\SCHOOL DATA\XII-CLASS DATA 2020-21\CS-PYTHON DATA\programes of class xii\projects
2020\MYSQL PROJECTS\MYSQL-4 KVS DATABASES - Copy.py
===================== Welcome To KVS Database ========================
1. Search the kv
2. Search the kv in Region table and Region_Wise
3. Search the kv in Zone table and Zone_Wise
4. Search the kv in station table and Station_Wise
5. Types of KVS
6. Regional-offices of KVS
7. Exit the program
===============================================================
Enter the choice of user 1
=========== Welcome to the KVS database ======================
1. Search the kv by KV_Name
2. Search the kv by KV_Code
3. Search the kv by city
4. Count the kv_school by region/zone wise
5. Exit the option
====================================================
KV Name : NASIRABAD
KV_Code : 1594
Zone_of_KV : WEST ZONE
Region_of_KV : JAIPUR
=================================================================
4 : No of kvs persent
1. Count the kvs zone_wise
2. Count the kvs Region_wise
3. Exit in the option
===============================================================
Enter the choice of user 2
================= Welcome Regions Department of KVS ======================
Region_code Region_name
==================================================
1 Ahmedabad
2 Bangalore
3 Bhopal
4 Bhubaneswar
5 mumbai
6 Kolkata
7 Chandigarh
8 Dehradun
9 Delhi
10 Guwahati
11 Hyderabad
12 Jabalpur
13 Jaipur
14 Jammu
15 Lucknow
16 Chennai
17 Patna
18 Silchar
19 KVS HQ
20 ZIET GWALIOR
21 ZIET MUMBAI
22 ZIET KOLKATA
23 ZIET CHANDIGARH
24 ZIET MYSORE
25 ZIET BHUBANESHWAR
26 AGRA
27 Ernakulam
28 Ranchi
29 Raipur
30 Varanasi
31 Silchar
32 Chandigarh
==================================================
32 : Regions found in the database
===============================================================
Enter the choice of user 3
================= Welcome Zone Department of KVS ======================
zone_code Zone_name
1 EAST ZONE
2 WEST ZONE
3 NORTH ZONE
4 CENTRAL ZONE
5 SOUTH ZONE
6 NORTH-EAST ZONE
============================================================
6 : zone found in the database
1. Search the kv
2. Search the kv in Region table and Region_Wise
3. Search the kv in Zone table and Zone_Wise
4. Search the kv in station table and Station_Wise
5. Types of KVS
6. Regional-offices of KVS
7. Exit the program
===============================================================
Enter the choice of user 4
===================== Welcome to Statation_type ================
H= HARD STATION
V= VERY HARD STATION
NER = NORTH-EAST REGION
=======================================================
1. Search the kv by hq/NER/V
2. Search the kv by H/V/NER by region_wise
3. Search the kv by H/V/NER BY ZONE_WISE
4. Exit in the option
1 EAST ZONE
2 WEST ZONE
3 NORTH ZONE
4 CENTRAL ZONE
5 SOUTH ZONE
6 NORTH-EAST ZONE
==================================================
6 : zone found in the database
1. Search the kv
2. Search the kv in Region table and Region_Wise
3. Search the kv in Zone table and Zone_Wise
4. Search the kv in station table and Station_Wise
5. Types of KVS
6. Regional-offices of KVS
7. Exit the program
===============================================================
Enter the choice of user 5
==================== Type of kvs =============================
1. No of kvs in ZIET
2. No of KVS in IIT-COLLEGE
3. No of KVS in BSF AREA
4. No of KVS in NAVY DEFFENCE
5. No of KVS in ARMY AREA
6. No of KVS in AIR_FORCE AREA(AFS)
7. No of KVS in central-army area
8. No of KVS in CANT. OR CRPF AREA
9. No of KVS under Railway depart.
10. No of KVS under OIL REFINARY
11. Exit in the option
The Zone-code :1
The Zone-Name : EAST ZONE
The ZIET-code : 2266
The ZIET-Name : ZIET BHUBANESHWAR
============================================================
The Zone-code :1
The Zone-Name : EAST ZONE
The ZIET-code : 1921
The ZIET-Name : ZIET KOLKATA
============================================================
The Zone-code :2
The Zone-Name : WEST ZONE
The ZIET-code : 1919
The ZIET-Name : ZIET MUMBAI
============================================================
The Zone-code :3
The Zone-Name : NORTH ZONE
The ZIET-code : 1922
The ZIET-Name : ZIET CHANDIGARH
============================================================
The Zone-code :4
The Zone-Name : CENTRAL ZONE
The ZIET-code : 1918
The ZIET-Name : ZIET GWALIOR
============================================================
The Zone-code :5
The Zone-Name : SOUTH ZONE
The ZIET-code : 1923
The ZIET-Name : ZIET MYSORE
============================================================
1. No of kvs in ZIET
2. No of KVS in IIT-COLLEGE
3. No of KVS in BSF AREA
4. No of KVS in NAVY DEFFENCE
5. No of KVS in ARMY AREA
6. No of KVS in AIR_FORCE AREA(AFS)
7. No of KVS in central-army area
8. No of KVS in CANT. OR CRPF AREA
9. No of KVS under Railway depart.
10. No of KVS under OIL REFINARY
11. Exit in the option
===================INDIAN-INSTITUTE-TECHNOLOGY=======================
============================================================
The Region-code :5
The Region-Name : Mumbai
The Zone-code :2
The Zone-Name : WEST ZONE
City Name : MUMBAI
The KV-IIT-Code : 1214
The KV-IIT-Name : MUMBAI IIT POWAI KVS HQ WEST ZONE
============================================================
The Region-code :6
The Region-Name : Kolkata
The Zone-code :1
The Zone-Name : EAST ZONE
City Name : KHAGARPUR
The KV-IIT-Code : 1260
The KV-IIT-Name : KHARAGPUR NO.I (IIT)
============================================================
The Region-code : 10
The Region-Name : Guwahati
The Zone-code :6
The Zone-Name : NORTH-EAST ZONE
City Name : GUWAHATI
The KV-IIT-Code : 1471
The KV-IIT-Name : GUWAHATI IIT
============================================================
The Region-code : 13
The Region-Name : Jaipur
The Zone-code :2
The Zone-Name : WEST ZONE
City Name : JODHPUR
The KV-IIT-Code : 2350
The KV-IIT-Name : IIT JODHPUR
============================================================
The Region-code : 15
The Region-Name : Lucknow
The Zone-code :4
The Zone-Name : CENTRAL ZONE
City Name : KANPUR
The KV-IIT-Code : 1731
The KV-IIT-Name : KANPUR IIT KVS HQ CENTRAL ZONE
============================================================
The Region-code : 16
The Region-Name : Chennai
The Zone-code :5
The Zone-Name : SOUTH ZONE
City Name : CHENNAI
The KV-IIT-Code : 1775
The KV-IIT-Name : CHENNAI IIT KVS HQ SOUTH ZONE
============================================================
The Region-code : 30
The Region-Name : Varanasi
The Zone-code :4
The Zone-Name : CENTRAL ZONE
City Name : ALLAHABAD
The KV-IIT-Code : 1714
The KV-IIT-Name : ALLAHABAD IIIT
============================================================
www.google.com
www.python.org
www.kvsrojaipuronline.com etc
THANK YOU