You are on page 1of 4

AISSCE PRACTICAL EXAMINATION 2022-23

INFORMATICS PRACTICES (065) SCHOOL CODE 64006


Date : 27-01-2023 (SET 1)
Max. Marks: 30 Time: 3:00 Hours

Q1 a. Program using Pandas: Consider the following data 5 marks


BookID Subject BookTitle Class Publisher Price
B0001 Computer Science NCERT Computer Science XII NCERT 270

B0002 Computer Science Move fast with computer science XII Dhanpat Rai 340

B0003 Computer Applications Sample Papers X BPB 120

B0004 Informatics Practices NCERT Informatics Practices XII NCERT 270

Write a program to create a dataframe for the given data, Also Show the DataFrame after deleting details
of BookID : B0004.

Q1 b.Program using Matplotlib : 3 marks


Write a Python program to plot a bar chart, showing the No. of Books published in respective year using
the following data.
No. of Books = [160,170,185,150,200]
Year = [2019,2020,2021,2022,2023]
Colour of bar should be red and the No of books and year labels should be displayed in the desired location
and also the title of plot should be “Books published Yearwise”.
Q2. MySQL Queries : 7 marks
RollNo Name Class Gender City Marks
1 Naman XII M Bhopal 453
2 Nandini X F Jaipur 551
3 Nakshatra X F Delhi 553
4 Shailesh XI M Chandigarh 458
5 Trisha XII F Delhi 430
6 Manisha XII F Jaipur 530
Consider the table RESULT2023 given below and answer the following questions:

(a) To display the details of class XII students in descending order of their marks.
(b) Display the sum of the marks of students who have scored more than 500.
(c) Find the maximum marks of the student for each class.
(d) Count the students class wise and display only those number which is more than 2.
(e) Display unique cities from the table.

Q3) Practical File : 5 marks


Q4) Project work: 5 marks
Q5) Viva-voce: 5 marks

Sign of Internal Examiner Sign of External Examiner


AISSCE PRACTICAL EXAMINATION 2022-23
INFORMATICS PRACTICES (065) SCHOOL CODE 64006
Date : 27-01-2023 (SET II)
Max. Marks: 30 Time: 3:00 Hours

Q1 a. Program using Pandas: 5 marks


Create a Dataframe “Humanoid”

SName Amount
H_1 Alexa 7000
H_2 Cortana 5000
H_3 Siri 4000

i. Write a command to display the records of the dataframe which have amount
greater than equal to 5000.
ii. How will you change the index from H_1,H_2,H_3 to 101,102,103
iii). Remove the column Amount.

Q1 b.Program using Matplotlib : 3 marks


Write a Python program to plot a bar chart, Pass percentage of XII in respective year using the following
data.
Pass_Percentage = [80,88,89,94,98]
Year = [2019,2020,2021,2022,2023]
Colour of bar should be Blue and the Pass Percentage year labels should be displayed in the desired
location and also the title of plot should be “Year wise Pass Percentage”.
Q2. MySQL Queries : 7 marks
RollNo Name Class Gender City Marks
1 Naman XII M Bhopal 453
2 Nandini X F Jaipur 551
3 Nakshatra X F Delhi 553
4 Shailesh XI M Chandigarh 458
5 Trisha XII F Delhi 430
6 Manisha XII F Jaipur 530
Consider the table RESULT2023 given below and answer the following questions:

(a) Display All the boys whose city is Bhopal.


(b) To display the details of class XII students in descending order of their marks.
(c) Display the Average of the marks of students who have scored more than 500.
(d) Find the maximum marks of the student for each class.
(e) Display All the student name starting with Letter “N”.

Q3) Practical File : 5 marks


Q4) Project work: 5 marks
Q5) Viva-voce: 5 marks

Sign of Internal Examiner Sign of External Examiner


AISSCE PRACTICAL EXAMINATION 2022-23
INFORMATICS PRACTICES (065) SCHOOL CODE 64006
Date : 27-01-2023 (SET III)
Max. Marks: 30 Time: 3:00 Hours

Q1 a. Program using Pandas: 5 marks


Create a Data Frame below and answer the questions that follow.
Name Weight Height
A_1 Pawan 50 153
A_2 Piyush 60 165
A_3 Prem 40 150
A_4 Prakash 70 145
A_5 Prateek 55 160
i) Which command will produce the following output to extract only a part of dataframe?
Piyush 60
Prem 40
Prakash 70
ii) What is the correct syntax to display the record of Piyush?

Q1 b.Program using Matplotlib : 3 marks


Mark is a list of marks of a student in 10 unit test .Write a Python program to plot a the students
performance in the test.
Week = [1,2,3,4,5,6,7,8,9,10]
Marks=[12,10,10,15,17,25,12,11,22,34,38]

Q2. MySQL Queries : 7 marks


RollNo Name Class Gender City Marks
1 Naman XII M Bhopal 453
2 Nandini X F Jaipur 551
3 Nakshatra X F Delhi 553
4 Shailesh XI M Chandigarh 458
5 Trisha XII F Delhi 430
6 Manisha XII F Jaipur 530
Consider the table RESULT2023 given below and answer the following questions:

(a) To display city wise total marks.


(b) To display the details of class XII students whose city is “Delhi”.
(c) Display the sum of the marks of students who have scored less than 500.
(d) Find the average marks of the student for each class.
(e) Display unique cities from the table.

Q3) Practical File : 5 marks


Q4) Project work: 5 marks
Q5) Viva-voce: 5 marks

Sign of Internal Examiner Sign of External Examiner


1. import pandas as pd
d={'BookID':['B0001','B0002','B0003','B0004'],'Subject':['Computer Science','Computer
Science','Computer Science','Informatices Practices'],'Book Title':['NCERT Computer
Science','Move fast with computer science','Sample Papers','NCERT Informatics
Practices'],'Class':['XII','XII','X','XII'],'PUBLISHER':['NCERT','Dhanpat
Rai','BPB','NCERT'],'Price':[270,340,120,270]}
df=pd.DataFrame(d)
print(df.set_index('BookID'))
df.drop(3,axis=0,inplace=True)
print("--------------------------------------------")
print(df)

2.import pandas as pd
dic={'Sname':['Alexa','Cortona','Siri'],'Amount':[7000,5000,4000]}
Humanoid=pd.DataFrame(dic,index=['H_1','H_2','H_3'])
print(Humanoid)
print("--------------------------------------------")
print(Humanoid[Humanoid['Amount']>=5000])
print("--------------------------------------------")
print(Humanoid.rename({'H_1':101,'H_2':102,'H_3':103}))
print("--------------------------------------------")
print(Humanoid.drop('Amount',axis=1))

3. import pandas as pd
d={'Name':['Pawan','Piyush','Prem','Prakash','Prateek'],'Weight':[50,60,40,70,55],'Height':[153,16
5,150,145,160]}
df_data=pd.DataFrame(d,index=['A_1','A_2','A_3','A_4','A_5'])
print(df_data)
print("--------------------------------------------")
print(df_data.iloc[1:4,0:2])
print("--------------------------------------------")
print(df_data[df_data['Name']=='Piyush'])
print("--------------------------------------------")

You might also like