Download as pdf or txt
Download as pdf or txt
You are on page 1of 85

KENDRIYA VIDYALAYA SANGATHAN AGRA REGION

FIRST PRE BOARD EXAMINATION (Session 2023-24)


Class : XII Time : 03:00 Hours
Subject : (065) Informatics Practices Maximum Marks : 70

General Instructions:
1. This question paper contains five sections, Section A to E.
2. All questions are compulsory.
3. Section A have 18 questions carrying 01 mark each.
4. Section B has 07 Very Short Answer type questions carrying02 marks each.
5. Section C has 05 Short Answer type questions carrying 03 marks each.
6. Section D has 02 Long Answer type questions carrying 04 marks each.
7. Section E has 03 questions carrying 05 marks each. One internal choice is
given in Q 35 against part c only.
8. All programming questions are to be answered using Python Language only.
9.

PART A
1. There are numerous websites, which provide search facility for searching the 1
contents on
a) Internet b) Website c)Web Page d) LAN
2. It is an act of copying another person’s data idea, words or work and pretended 1
that they are our own.
a) Copyright b) Virus c) Plagiarism d) IPR
3. Feasible method(s) to manage e-Waste. 1
a) Reducing b) Reusing c) Recycling d) All of these
4. Which type of values will not considered by SQL while executing the following 1
statement?
SELECT COUNT(column name) FROM INVENTORY;
a) Numeric value
b) Text value
c) Null value
d) Date value
5. In column “Margin “contains the data set(2.00,2.00,NULL,4.00,NULL,3.00,3.00) 1
what will be the output of after the execution of the given query?
SELECT AVG(Margin) FROM SHOP;
a) 2.9 b) 2.8 c)2.00 d) All of these

Page 1 of 10
6. ‘P’ in IPR stands for 1
a) Proprietary
b) Platform
c) Patent
d) Property
7. Which of the following is not a category of MySQL functions? 1
a) Text Functions
b) Mathematical Functions
c) Statistical Group Functions
d) Memory Handling Functions

8. What is the output of the following SQL Command : 1


SELECT ROUND(458.45,-1)
a) 460
b) 450
c) 458
d) 500
9. Which of the following function is the correct syntax of LCASE() function? 1
a) LCASE(row_name)
b) LCE(column_name)
c) LCASE(string/column_name)
d) None of the above
10. To display Third Element of a Series object S, you will write : 1
a) S[:3]
b) S[2]
c) S[3]
d) S[:2]
11. 1
Which of the following is a 2-dimensional array containing a sequence of
values in Python?
(a) Relation
(b) DataFrame
(c) Series

Page 2 of 10
(d) Square

12. What will be the output of the Python program mentioned below ? 1
import pandas as pd
df=pd.DataFrame(['Apple','Banana','Orange','Grapes','Guava'])
print(df[2:4:2])
a) 0
2 Orange
b) Empty DataFrame
Columns:[0]
Index:[ ]
c) 0
2 Banana
d) 0
2 Banana
4 Grapes
13. An online discussion group that allow direct live communication is known as 1
a) e-mail
b) Hyperlink
c) Chat group
d) Web Crawler
14. Which function extracts the year value from a date. 1
a) CURRENT( )
b) DAY-YEAR( )
c) YEAR( )
d) MONTH( )
15. What is the name of the IT law that India is having in the Indian Legislature? 1
a) India’s Technology(IT) Act,2000
b) India’s Digital Information Technology(DIT),Act,2000
c) India’s Information Technology(IT),Act ,2000
d) The Technology Act,2008
16. Which of the following are automatically granted to creators and authors? 1
a) Copyright
b) Patent
c) Trademark
d) Netiquette

Page 3 of 10
Q17 and 18 are ASSERTION AND REASONING based questions. Mark the
correct choice as
i. Both A and R are true and R is the correct explanation for A
ii. Both A and R are true and R is not the correct explanation for A
iii. A is True but R is False
iv. A is false but R is True
17. ASSERTION (A): MODEM stands for modulator-demodulator 1
REASONING(R): It is a computer hardware device that converts data from a
digital format to analog and vice versa

18. ASSERTION(A):drop() function removes data from a Dataframe temporarily. 1

REASONING(R): Axis parameter is compulsory with drop() function.

PART B
19 What is a Website and Webpage? 2
OR
What is a network? Why is it needed?
20 Gopi Krishna is using a table Employee .it has the following Columns: 2
Code,Name,Salary,Deptcode

SELECT Deptcode,MAX(Salary) FROM Employee;


He wants to display maximum salary for each department. But he did not get the
desired result .Rewrite the above query with necessary change to help him get the
desired result.
21. What is NULL ? How it is different from Zero ? How are NULL values treated 2
by aggregate functions?
22. Consider the given Series object Subject: 2
Index Marks
English 75
Hindi 78
Math 82
Science 88

Page 4 of 10
Write a program in python pandas to create this series using a dictionary.

23. Name the methods for proper treatment of e-waste. 2


OR
What is meant by digital footprint and how to manage it suggest any two
guidelines.
24. What will be the output of the following code: 2

>>>import pandas as pd
>>>nums=pd.Series([9,8,7,6,5],index=range(0,10,2))
>>>print(nums[1:3])
25. Consider the code given below and answer the following question: 2
Ld=[{'a',10,'b':20},{'a':5,'b':10,'c':20}]
df=pd.DataFrame(Ld)
print(df)
i) Write the missing statement in the above code which will give error.
ii) How many columns will be there in the dataframe.
SECTION C

26 Consider a table “Salesman” with the following data: 3


Table : Salesman

Sno Sname Salary Bonus DOJ


A01 Beena Mehta 30000 45.23 2019-10-29
A02 K.L. Sahay 50000 25.34 2018-03-2013
B03 Nisha Thakkar 30000 35.00 2017-03-18
B04 Leela Yadav 80000 NULL 2018-12-31
C05 Gautam Gola 20000 NULL 1989-01-23

Write SQL queries using SQL functions to perform the following operations.
(i) Display salesman name and bonus after rounding off to zero decimal places.
(ii) Display the month name for the date of join of salesman.
(iii) Display the minimum salary of the Salesman.
OR
Page 5 of 10
What is the purpose of GROUP BY clause in MySQL? How is it different from
ORDER BY clause?
27. Write a python code to create a DataFrame with appropriate column headings 3
from the list given below:
[[201,’Gurmeet’,95],[202,’Praveen’,89],[203,’Suman’,97],[204.’Yogesh’,91]]

28. Consider the given DataFrame ‘Fees’: 3

Cname Fee
0 XII 3500
1 XI 3000
2 X 2700
3 VII 1800

Write suitable Python statements for the following:


i. Add a column called ‘Section’ with the following data:
[‘A’,’B’,’C’,’D’].
ii. Add a new Class Name named ‘IX' having price 1800 and Section “B”.
iii. Remove the column ‘Section’.
29 Samridh has recently changed his school so he is not aware of the people, but 3
someone is posting negative demeaning comments on his social media profile.
He is also getting repeated mails from unknown people. Every time he goes
online, he finds someone chasing him online.
i. Samridh is a victim of ___________.
ii. The action that Samridh should take to handle it.
iii. .......................... is a set of moral principles that governs the behavior of a
group or individual and regulates the use of computers.
OR
What Is the Difference Between a Patent, Copyright, and Trademark?
30. Write SQL commands for the statements (i) to (iii) which are based on the given 3
table PERSON.

Page 6 of 10
PI PINCO SALAR
SNAME FNAME GEN CITY
D DE Y
SHARM UDHAMW
1 GEET F 182141 50000
A ARA
SURINDE
2 SINGH M KUPWARA 193222 75000
R
3 JCOB PETER M BHAWANI 185155 45000
AHMED
4 ALVIS THOMAS M 380025 50000
NAGAR
COOLANG
5 MOHAN GAURAV M 390026 33000
ATTA
NEW
6 AZMI SIMI F 110021 40000
DELHI
MANPRE UDHAMW
7 KAUR F 182141 42000
ET ARA

i) SELECT SUM(SALARY) FROM PERSON WHERE GEN=’F’;


ii) SELECT GEN,COUNT(*) FROM PERSON GROUP BY
GENDER;
iii) SELECT MOD(SALARY,4000) FROM PERSON WHERE
CITY=‘UDHAMWARA’;

SECTION D
31 Naveen, a database administrator has designed a database for a Computer Stock. 4
Help her by writing answers of the following questions based on the given table:
TABLE: Stock
Pid Pname Category Qty Price
1 Keyboard IQ 15 450
2 Mouse IQ 10 350
3 Wi-fi router NW 5 2600
4 Switch NW 3 3000
5 Printer O 4 17000

i. Write a query to display product name in upper case.


ii. To display the records in descending order of the price.
iii. To display category and category wise highest price of product.
IV. To display the total quantity of all products.

Page 7 of 10
32. Mr. Ankit is working in an organization as data analyst. He uses Python Pandas
1+1+2
and Matplotlib for the same. He got a dataset of the passengers for the year 2010
to 2012 for January, March and December. His manager wants certain information
from him, but he is facing some problems. Help him by answering few questions
given below:
Year Month Passengers
0 2010 Jan 25
1 2010 Mar 50
2 2012 Jan 35
3 2010 Dec 55
4 2012 Dec 65

A. Predict the output of the following python statement:


i. df.tail(3)
ii. df[df.Passengers>50]
iii.Write Python statement to display the data of year column of indexes 1 to 3.
OR (Option for part iii only)

Write the Python code to rename the name of the column name is ‘mon_name’in
place of “Month” in the above Dataframe.

SECTION E

33. Write suitable SQL query for the following: 5


i. Display 7 characters extracted from 7th left character onwards from the
string ‘INDIA SHINING’.
ii. Display the position of occurrence of string ‘COME’ in the string
‘WELCOME WORLD’.
iii. Round off the value 78.779 to 2nd decimal place.
iv. Display the remainder of 149 divided by 6.
v. Remove all the expected leading and trailing spaces from a column userid
of the table ‘USERS’ and convert to lowercase.
OR

Page 8 of 10
Explain the following SQL functions using suitable examples.
i. LENGTH()
ii. TRIM()
iii. NOW()
iv. DAYNAME()
v. POWER()
v. POWER(
34. Trine Tech Corporation (TTC) is a professional consultancy company. The 5
company is planning to set up their new offices in India with its hub at Hyderabad.
As a network adviser, you have to understand their requirement and suggest them
the best available solutions. Their queries are mentioned as (i) to (v) below.
Physical location of the blocks of TTC

Human Conference
Resources Block Block

Finance Block

Blocks to block distance(in meter)


Block(From) Block(To) Distance
Human Resource Conference 110
Human Resource Finance 40
Conference Finance 80
Expected number of computers to be in each block
Block Computers
Human Resource 25
Finance 120

Conference 90
(i)Which will be the most appropriate block, where TTC should plan to install their
server?
(ii) Draw a block to block cable layout to connect all the buildings in the most
appropriate manner for efficient communication.

Page 9 of 10
(iii) Which of the following device will be suggested by you to connect each
computer in each of the buildings?
(a) Switch
(b) Modem
(c) Gateway
(iv) The company is planning to connect its admission office to Hyderabad which
is more than 1000 km from company. Which type of network will be formed?
(v)what will be the best possible connectivity out f the following you will suggest
to connect the new setup of offices in Hyderabad with its London based office.
a) Satellite Link
b) Infrared
c) Ethernet
35 Mr. Sharma is working in a game development industry and he was comparing the 5
given chart on the basis of the rating of the various games available on the play
store.

Write the python code for the above graph – each bar having a different color and
X – axis and Y – axis having a suitable lable. Also give suitable python statement
to save this chart.
OR
Write a python program to plot a line chart based on the given data to depict
the pass percentage of students in CBSE exams for the years 2015 to 2018 as
shown below.
Year=[2015,2016,2017,2018]
Pass_Percentage=[82,83,85,90]

END OF PAPER

Page 10 of 10
Page 11 of 10
KENDRIYA VIDYALAYA SANGTHAN AGRA REGION
First PREBOARD EXAMINATION 2023-24
MARKING SCHEME
CLASS XII
INFORMATICS PRACTICES(065)
TIME:3 HOURS M.M.70
General Instructions:
1. This question paper contains five sections, Section A to E.
2. All questions are compulsory.
3. Section A have18 questions carrying 01 mark each.
4. Section B has 07 Very Short Answer type questions carrying 02 marks each.
5. Section Chas 05 Short Answer type questions carrying 03 marks each.
6. Section D has 02 Long Answer type questions carrying 04 marks each.
7. Section E has 03 questions carrying 05 marks each.
8. All programming questions are to be answered using Python Language/SQL
only.

SECTION A
1. a)Internet 1
1 mark for correct answer
2. c)Plagiarism 1
1 mark for correct answer
3. d) All of these 1
1 mark for correct answer
4. c)Null value 1
1 mark for correct answer
5. b) 2.8 1
1 mark for correct answer
6. d) Property 1
1 mark for correct answer
7. d) Memory Handling Functions 1
1 mark for correct answer
8. a) 460 1
1 mark for correct answer
9. c)LCASE(str/column_name) 1
1 mark for correct answer
10. b) S[2] 1
1 mark for correct answer
11 (b) DataFrame 1
1 mark for correct answer

PAGE 1 OF 6
12. (a) 0 1
2 Orange
1 mark for correct answer
13. c)Chat group 1
1 mark for correct answer
14. c)YEAR() 1
1 mark for correct answer
15. c)India’s Information Technology(IT),Act ,2000 1
1 mark for correct answer
16. a) Copyright 1
1 mark for correct answer
Q17and18 are ASSERTION AND REASONING based questions. Mark the correct
choice as
i. Both A and R are true and R is the correct explanation for A
ii. Both A and R are true and R is not the correct explanation for A
iii. A is True but R is False
iv. A is false but R is True
17. i) Both A and R are true and R is the correct explanation for A 1

18. i) Both A and R are true and R is the correct explanation for A 1
.
SECTION B
19 Website: A group of related webpages that follow the same theme and 2
are connected together with hyperlinks is called a Website.
Webpage: web page is an electronic document designed using HTML.it
displays information in textual or graphical form.
1 mark for correct explanation of each term
OR
Network: A network is an interconnected collection of autonomous computers that
can share and exchange information.
1 mark for correct explanation

Need of Networking:
i. Resource sharing
ii. Reliability
iii. Cost effective
iv. Fast data sharing
½ mark for each (any two)
20 SELECT Deptcode, MAX(Salary) FROM Employee GROUP BY Deptcode; 2

1 Mark for error identification


1 Mark for writing correct query

PAGE 2 OF 6
21. Null is a Specifier / Constraint represents that the actual value is absent for the ½+1
particular column. Null is different from zero because zero is a Numeric Value that +½
can be used in Arithmetic / Logical operations but NULL can not be used like this.
None of the aggregate functions takes NULL into consideration. NULL is simply
Ignored by all the aggregate functions excepts COUNT(*).
2 marks for correct answer with example.
22. import pandas as pd 2
d={‘English’:75,’Hindi’:78,’Math’:82,’Science’:88}
Subject=pd.Series(d)
print(Subject)
½ marks for import statement
½ marks for using dictionary
1 mark for creating Series( )
23. 1.Recycling/recovery of valuable material. 2
2.Dismantling
3. Refurbishment and reuse
4. Disposal of dangerous materials and waste

½ mark for each correct answer


OR
On the internet, a digital footprint is the word used to describe the train, traces or
footprints that people leave online. This is information transmitted online, such as
forum registration-mails and attachments, uploading videos or digital images.
1mark for each correct answer
Guidelines of Digital Footprint
1.know what your digital footprints is
2.keep your digital foot print clean
½ mark for each correct point

24. 2 8 2
4 7
1 mark for each correct row
25. i) import pandas as pd 2
ii) 3 columns
1 mark for each correct answer

SECTION C
26 ANS: 3
(i) SELECT Sname, ROUND(Bonus,0)FROM Salesman;
(ii) SELECT MONTHNAME(DOJ) FROM Salesman;
(iii) SELECT MIN(SALARY) FROM Salesman;
1 mark for each correct query
OR
The GROUP BY clause can be used to combine all those records that have identical
value in a particular field or a group of fields. Whereas, ORDER BY clause is used
to display the records either in ascending or descending order based on a particular
field. For ascending order ASC is used and for descending order, DESC is used. The

PAGE 3 OF 6
default order is ascending order.
1 mark for correct significance 2 marks for correct example

27 import pandas as pd 3
data=[[201,’Gurmeet’,95],[202,’Praveen’,89],[203,’Suman’,97],[204.’Yogesh’,91]]
df=pd.DataFrame(data,columns=['Rno','Name', 'Marks'])
1 mark for each correct python statement
28 i. Fees['Section']= [‘A’,’B’,’C’,’D’]
ii. Fees.loc['4']=['IX',1800]
iii. Fees=Fees.drop('Section',axis=1)
1 mark for each correct statement
29 i. Cyber stalking 3
ii. He should bring to the notice of his parents and school authorities.
iii. Computer ethics

OR 3
A patent protects new inventions, processes.
A copyright protects original works of authorship.
A trademark includes words, phrases, designs, or any combination of
these that particularly identify a good or service.

30. Write SQL commands for the statements (i) to (iii) which are based on the given 3
table MASTER.
i)132000
ii)GEN COUNT(*)
F 3
M 4
ii) 2000
2000
SECTION D
31 i. SELECT UPPER(PNAME) FROM STOCK; 4
ii. SELECT * FROM STOCK ORDER BY PRICE DESC;
iii. SELECT CATEGORY,MAX(PRICE) FROM STOCK GROUP BY CATEGORY;
IV SELECT SUM(QTY) FROM STOCK;
1 mark for each correct query

PAGE 4 OF 6
32. A)
i) 2 2012 Jan 35 1+1+2
3 2010 Dec 55
4 2012 Dec 65
ii) 55
65
1 mark for each correct output
B ) Python statement:
print(df.loc[1: 3, 'year'])
OR
df.rename(columns={‘Month’ : ’mon_name’)

2 marks for correct Python statement

SECTION E
33. i. select mid('INDIA SHINING',7,7); 5
ii. select INSTR('WELCOME WORLD','COME');
iii. select round(78.779,2);
iv. select mod(149,6);
v. select lower(trim(userid)) from users;

1 mark for each correct query


OR
1. LENGTH():This function returns the length of the string in bytes. It includes the count of
blank spaces in the string.
Syntax
LENGTH(string/column_name)
EXAMPLE :
SELECT LENGTH('easycalculation');
Output:
15
2. TRIM(): It removes the leading and trailing spaces from the given string.
Example:
SELECT TRIM(‘ Welcome world ‘ );
Output:
Welcome world
3. This function returns the current date and time in the format ‘YYYY-MM-DD
HH:MM:SS’ or YYYYMMDDHHMMSS format.
Syntax NOW()
e.g. mysql> SELECT NOW()
Output:
‘YYYY-MM-DD HH:MM:SS’ or YYYYMMDDHHMMSS format of current date
4. DAYNAME(): It returns the weekday name for a given date
Example:
SELECT DAYNAME(‘2022-07-22’);
PAGE 5 OF 6
Output:
Friday
5. POWER(): It returns the value of a number raised to the power of another number.
Example:
SELECT POW(6,2);
Output:
36
½ mark for each correct explanation
½ mark for each correct example

34. i) TTC should install its server in finance block as it is having maximum number of 5
computers.
ii) Human Resources Conference Block
Block

Finance Block

The above layout is based on minimum cable length required which is 120 meter in
the above case.
iii) Switch
iv)WAN
v) Satellite Link
35 import matplotlib.pyplot as plt 5
Games=["Subway Surfer","TempleRun","CandyCrush","BottleShot","RunnerBest"]
Rating=[4.2,4.8,5.0,3.8,4.1]
plt.bar(Games,Rating,color = [“green”,”red”,”yellow”,”cyan”,”magenta”])
plt.xlabel("Games")
plt.ylabel("Rating”) plt.show()
½ mark for each correct statement
Python statement to save the chart:
plt.savefig("aa.jpg")
1 mark for the correct statement
OR
import matplotlib.pyplot as plt 1/2MARK
Year=[2015,2016,2017,2018] 1/2 MARK
Pass_Percentage=[82,83,85,90] 1 MARK
plt. plot(Year,Pass_Percentage) 1 MARK
plt.xlabel("Year") 1/2 MARK
plt.ylabel("Pass_Percentage”) 1/2 MARK
plt.show() 1 MARK

END OF PAPER

PAGE 6 OF 6
KENDRIYA VIDYALAYA SANGATHAN, CHENNAI REGION
PRE BOARD EXAMINATION 2023-24 12INF01 QP
CLASS XII SUBJECT: INFORMATICS PRACTICES (065)
TIME: 03 Hours M.M.:70

General Instructions:
1. This question paper contains five sections, Section A to E.
2. All questions are compulsory.
3. Section A have 18 questions carrying 01 mark each.
4. Section B has 07 Very Short Answer type questions carrying 02 marks each.
5. Section C has 05 Short Answer type questions carrying 03 marks each.
6. Section D has 02 questions carrying 04 marks each.
7. Section E has 03 questions carrying 05 marks each.
8. All programming questions are to be answered using Python Language only.

SECTION A
1 ATM network of an bank in a city is an example of : 1
a) PAN b) LAN c)WAN d)MAN
2 Which of the following is NOT a type of a cyber-crime? 1
a) Identity theft
b) Software privacy
c) Installing antivirus software
d) Hacking
3 To display first four elements of a Series S 1
a) S[:4]
b) S.head[4]
c) S[4:]
d) both a) and b)
4 Which of the following SQL function will display the current time and date? 1
a) NOW() b)DATE() c)YEAR() d) Both a) & b)
5 Which of the following devices can connect different sub networks? 1
a) Hub b) Switch c) Repeater d) Router
6 Which of the following SQL function does NOT belong to the Math function category? 1
a) POWER() b)ROUND() c)LENGTH() d)MOD()
7 IPR stands for ____ 1
a) Interactive Property Resources
b) Intellectual Property Rights
c) Interactive Property Rights
d) Intellectual Property Resources
8 For which of the command the output will be 69.77 1
a) Select round(69.7654,3)
b) Select truncate(69.7654,3)
c) Select round(69.7654,2)
d) Select truncate(69.7654,2)
9 Which library is to be imported for creating DataFrame? 1
a) DataFrame b)Python c)Random d)Pandas
10 Which of the following is not the attribute of DataFrame? 1
a)empty b)size c)type d)columns
11 The _____________ function is used in SQL to find one string into another. 1
a)substr() b)instr() c)mid() d)left()
12 Code of the software will be protected by ___________ 1
a) Copyright b) Patent c) registered trademark d) none of these
13 ______ clause is used with SELECT statement to display data in a sorted form with respect to a 1
specified column
a) WHERE b)ORDER BY c) HAVING d) DISTINCT
14 What is an example of e-waste? 1
a) A ripened banana
b) An old computer
c) Old clothes
d) Empty soda cans
15 To remove the leading and trailing space from data values in a column of MySQL table, we use 1
a) Left() b) Right() c) Trim() d)Rtrim()
16 Which of the following is Net etiquette? 1
a) Be Ethical
b) Be Respectful
c) Be Responsible
d) All of the above
17 Assertion (A): Internet cookies are text files that contain small pieces of data like a username, 1
password while surfing the internet.
Reason (R): To make browsing the internet faster & easier, its required to store certain
information on the server’s computer.
a)Both A and R are true and R is the correct explanation for A
b)Both A and R are true and R is not the correct explanation for A
c) A is True but R is False
d)A is false but R is True
18 Assertion (A): To delete a column from Panda DataFrame, drop () method is used. 1
Reason (R) : Columns are deleted by dropping columns with index label.
a)Both A and R are true and R is the correct explanation for A
b)Both A and R are true and R is not the correct explanation for A
c) A is True but R is False
d)A is false but R is True
SECTION B
19 Differentiate between static and dynamic webpage. 2
Or
Mention any four networking goals.
20 The python code written below has syntactical errors. Rewrite the correct code and underline the 2
corrections made.
import Pandas as pd
Import numpy as np
s=pd.Series[1,2,3,4]
Print(s.index)
21 Consider the given SQL string: 2
“Informatics Practices Exam”
Write suitable SQL queries for the following:
i. Returns the position of the first occurrence of the substring “mat” in the given string.
ii. To extract last six characters from the string
22 What will be the output of the following code: 2
>>>import pandas as pd
>>>A=pd.Series(data=[16,25,45,20])
>>>print(A>30)
23 What is identity theft? Give example 2

24 Complete the given Python code: 2


import pandas as pd
import numpy as np
Name = _________ .array([‘Anil’,’Sumit’,’Akhil’,’Ananya’])
___________ = __________ . DataFrame(____)
print(DF)
25 Briefly explain the purpose of the following: 2
i. power()
ii. mod()
SECTION C
26 Based on the SQL table EXAM, write suitable queries for the following: 3

Adno SName Percentage clasection Stream


1001 Sai 80.5 12A Science
1002 Krish 90.5 12B Commerce
1003 Swathika 94.5 12A Science
1004 Malavika 76.7 12A Science
i. To display all information of the students of Commerce in descending order of
percentage
ii. To display Adno, SName, Percentage of those students whose name is less than 6
characters long.
iii. To insert a new row in the table EXAM (1005,’Ananya’,65.5,’12B’,’Commerce’)
OR
Predict the output of the following queries based on the table EXAM given above:
i. SELECT COUNT * FROM EXAM;
ii. SELECT SName, Percentage FROM EXAM WHERE Name LIKE “N%”;
iii. SELECT ROUND (Percentage, 0) FROM EXAM WHERE Adno = “1004”;

27 Create a DataFrame in Python from the given list: 3


[[‘Kavya’, 250],[‘Ananya’,150],[‘Malini’,185],[‘Raja’,320]]
Also give appropriate column headings as shown below:
Name Wages
0 Kavya 250
1 Ananya 150
2 Malini 185
3 Raja 320
28 Predict the output of the following SQL queries 3
i. SELECT TRIM (“ ALL THE BEST “);
ii. SELECT LEFT(‘INFORMATICS’,6);
iii. SELECT UPPER(MID(“START UP INDIA”,10));

29 Mr, Ram who is a business man by profession faced following situations. Identify the type of 3
crime for each situation/incident happened to him?
i. He was constantly receiving abusive emails.
ii. He clicked on an unknown link received as a result his personal sensitive information
was acquired by someone
iii. His identity was used by someone to steal money.
OR
What are some side effects of spending too much time on computers?
30 Consider the given DataFrame ‘ Stock’ 3

Name Price
0 BSE 250
1 NSE 150
2 INX 185
3 MCX 320

Write suitable Python statements for the following:


i. Add a column called Special_Price with the following data: [220,115,145,285].
ii. Add a new Stock of Name ‘NCDEX’ having Price as 280
iii. Remove the column Price.
SECTION D
31 Vijay manages a database with the latest price of Electronic Devices. He created a table named 4
DEVICES. Assist him by writing the following Queries:

TABLE: DEVICES
PID PName Category Qty Price
1 Keyboard IO 15 450
2 Mouse IO 10 350
3 Wifi-router NW 5 2600
4 Switch NW 3 3000
5 Monitor O 10 4500
6 Printer O 4 17000
i. To display the records in decreasing order of Price.
ii. To display category and category wise total quantities of products.
iii. To display the category and its average Price.
iv. To display category and category wise highest price of the products.
32 Ram designed the DataFrame df that contains the temperature of different cities as shown 4
below:
City Maxtemp Mintemp Avgtemp Rainfall
0 Delhi 40 32 35 24.1
1 Mumbai 31 23 27 32.6
2 Chennai 29 21 25 26.2
Answer the following Questions:
i. Predict the output of the following python statement:
a. Print(df.size)
b. Print(df[1:3])
ii. Delete the last row from the DataFrame.
iii. Write python statement to add a new city named ‘Calcutta’ having Maxtemp 28,
Mintemp 19, Avgtemp 24, Rainfall 20.1
SECTION E
33 Write suitable SQL queries for the following: 5
i. Display name of the month from your date of birth.
ii. Convert email-id to lowercase
iii. Count the number of characters in your name
iv. To remove leading spaces from the ‘ VANDE BHARAT ‘.
v. Display the string ‘CHEST’ from the string ‘MANCHESTER UNITED’.

OR
Sanya has created following table named exam:

RegNo Name Subject Marks


1 Dhanya Computer Science 98
2 Sanjay IP 100
3 Vimala CS 85
4 Sneha IP 75
5 Akshay IP 100

Help him in writing SQL queries to perform the following task:


i. Insert a new record in the table having following values: [6,’Aarav’,’CS’,65]
ii. To change the value “IP” to “Informatics Practices” in subject column.
iii. To remove the records of those students whose marks are less than 40
iv. To add a new column Grade of suitable datatype.
v. To display records of “ Computer Science” subject

34 Learn together classes, is setting up its new campus at Jabalpur for its web- based activities. The 5
campus has 4 compounds:

.
Center to center distance is as follows:

Number of computers:

(i) Suggest the cable layout of connections between the compounds


(ii) Suggest the most suitable place to house the server. Justify your answer.
(iii) Suggest the placement of following devices with justification:
a)repeater b)hub/switch
(iv) Classes is planning to establish connection with its International office situated at
Mumbai, which out of the following wired communication will give very high speed
connectivity?
a)Telephone lines b)Optical fiber c) Ethernet d) All of them
(v) What kind of network will it be:
a)LAN b)WAN c)MAN d)PAN
35 Consider that survey has to be done on how much distance the following vehicles have covered 5
in a span of five days. Write suitable Python code to generate a Line Plot based on the given
data, along with an appropriate chart title and both axis labels.

BIKES
DAYS DISTANCE COVERED IN KMS
ENFIELD HONDA YAMAHA KTM
DAY 1 50 80 70 80
DAY 2 40 20 20 20
DAY 3 70 20 60 20
DAY 4 80 50 40 50
DAY 5 20 60 60 60

OR
Write a Python code to the following data for plotting the bar graph. Add the title, label for X-
axis, Y-axis.

English : 56,78,90,34
Science: 65,77,54,32
Maths: 45,67,43,41
KENDRIYA VIDYALAYA SANGATHAN, CHENNAI REGION
PRE BOARD EXAMINATION 2023-24 12INF01 MS
CLASS XII SUBJECT: INFORMATICS PRACTICES (065)
TIME: 03 Hours M.M.:70

General Instructions:
1. This question paper contains five sections, Section A to E.
2. All questions are compulsory.
3. Section A have 18 questions carrying 01 mark each.
4. Section B has 07 Very Short Answer type questions carrying 02 marks each.
5. Section C has 05 Short Answer type questions carrying 03 marks each.
6. Section D has 02 questions carrying 04 marks each.
7. Section E has 03 questions carrying 05 marks each.
8. All programming questions are to be answered using Python Language only.

SECTION A
1 c) WAN 1
2 c) Installing Antivirus software 1
3 a) S[:4] 1
4 a)Now() 1
5 b)Switch 1
6 c)LENGTH() 1
7 b) Intellectual Property Rights 1
8 c)Select round(69.7654,2) 1
9 d)Pandas 1
10 c) type 1
11 b)instr() 1
12 a)copyright 1
13 b)ORDER BY 1
14 b)An old computer 1
15 c)Trim() 1
16 d)All of the above 1
17 Option a) is correct. 1
18 Option c) is correct. Explanation: To delete a column from Pandas DataFrame, drop () method is 1
used. Columns are deleted by dropping columns with column names
SECTION B
19 Static web page: 2
 Content on the server is served upto any visitor the same(every time)
 Contains simple HTML code
 No additional software is required
Dynamic web page:
 Content on the server is the same, but displays different data depending on information searched
 Contains dynamic code along with simple HTML code
 Additional software must be installed on the server to create the web page.
(1 mark for each correct differentiation)
OR
Four networking goals
i. Resource sharing
ii. Reliability
iii. Cost effective
iv. Fast data sharing (1/2 mark for each goals)
20 import pandas as pd 2
import numpy as np
s=pd.Series([1,2,3,4])
print(s.index)
(1/2 mark for each correction)
21 i. SELECT INSTR(“Informatics Practices Exam”, “mat”); 2
ii. SELECT RIGHT(“Informatics Practices Exam”,6);
(1 mark for each correct query)
22 0 False 2
1 False
2 True
3 False
(2 marks for correct output)
23 Stealing someone’s personal identifying information and pretends to be that person in order to 2
gain some financial benefits. Eg.:- using stolen credit card information.
(2 marks for correct explanation)
24 import pandas as pd 2
import numpy as np
Name = np.array([‘Anil’,’Sumit’,’Akhil’,’Ananya’])
DF = pd. DataFrame(Name)
print(DF)
(1/2 mark for each correct fill-up)
25 i. pow(m,n) returns the value m raise to power n 2
ii. mod(a,b) returns the remainder after a divide by b
(1 mark for each correct explanation )
SECTION C
26 i. SELECT * FROM EXAM WHERE Stream =’Commerce’ ORDER BY Percentage 3
DESC;
ii. SELECT Adno, SName, Percentage FROM EXAM WHERE LENGTH (SName)<6;
iii. INSERT INTO EXAM VALUES (1005,’Ananya’,65.5,’12B’,’Commerce’);
(1 mark for each correct query)
OR
i.
COUNT (*)
4
ii. The given query will result in an error as there is no column named Name in table
EXAM
iii.

ROUND(Percentage ,0)
77
(1 mark for each output)
27 import pandas as pd # Statement 1 3
df=[[“Kavya”,250], [“Ananya”,150], [“Malini”, 185], [“Raja”,320]] #Statement 2
df=pd.DataFrame(df,columns=[“Name”, “Wages”]) #Statement 3
print(df) # Statement 4
(#Statement 1 & 4 – ½ mark each)
(#Statement 2 & 3 –1 mark each)
28 i. “ALL THE BEST “ 3
ii. INFORM
iii. INDIA
(1 mark for each output)
29 i. Cyber Bullying 3
ii. Phishing
iii. Identity theft
(1 mark for each correct answer)
OR
i. The Internet can be addictive
ii. Can have a negative impact on our physical and psychological well being
iii. Muscle and joint problems
iv. Overuse injuries like swelling, pain, joint stiffness, weakness and numbness.
v. Eyestrain
(3 mark for any 3 correct explanation)
30 i. Stock[‘Special_Price’] = [220,115,145,285] 3
ii. Stock.loc[4] =[‘NCDEX’,280]
iii. Stock.drop([‘Price’], axis=1,inplace=True)
(1 mark for each correct statement)
SECTION D
31 i. SELECT * FROM DEVICES ORDER BY PRICE DESC; 4
ii. SELECT CATEGORY, SUM(QTY) FROM DEVICES GROUP BY CATEGORY;
iii. SELECT CATEGORY, AVG(PRICE) FROM DEVICES GROUP BY
CATEGORY;
iv. SELECT CATEGORY, MAX(PRICE) FROM DEVICES GROUP BY
CATEGORY;
(1 mark for each correct query)
32 i. a.15 4
b. City Maxtemp Mintemp Avgtemp Rainfall
1 Mumbai 31 23 27 32.6
2 Chennai 29 21 25 26.2
(1 mark for each correct output)
ii. df=df.drop(2)
or
df,drop(2,axis=0)
(1 mark for correct statement)
iii. df.loc[4]=[‘Calcutta’, 28,19,24,20.1]
(1 mark for correct statement)

SECTION E
33 i. SELECT MONTHNAME(‘2022-10-12’); 5
ii. SELECT LOWER(‘abcd@gmail.com’);
iii. SELECT COUNT(‘SHAHEETH’);
iv. SELECT LTRIM(‘ VANDE BHARAT ‘);
v. SELECT MID(‘MANCHESTER UNITED’,4,5);
(1 mark for each correct query)
OR
i. INSERT INTO EXAM VALUES(6,'Aarav','CS',65);
ii. UPDATE EXAM SET subject= "Informatics Practices" where subject = "IP";
iii. DELETE FROM EXAM WHERE marks <40;
iv. ALTER TABLE EXAM ADD COLUMN Grade varchar(2);
v. Select * from exam where subject="Computer Science";
(1 mark for each correct query)
34 (i) 5

(ii) Training Compound


(iii) (a)Repeater – not required as distance is less than 100 m
(b)hub- training compound
(iv) Optical fiber
(v) WAN
(1 mark for each correct answer)
35 import matplotlib.pyplot as plt 5
x=[1,2,3,4,5]
y=[50,40,70,80,20]
y2=[80,20,20,50,60]
y3=[70,20,60,40,60]
y4=[80,20,20,50,60]
plt.plot(x,y,’g’,label=’Enfield’,linewidth=5)
plt.plot(x,y2,’c’,label=’Honda’,linewidth=5)
plt.plot(x,y3,’k’,label=’Yamaha’,linewidth=5)
plt.plot(x,y4,’y’,label=’KTM’,linewidth=5)
plt.title(‘bike details in line plot’)
plt.ylabel(‘Distance in kms’)
plt.xlabel(‘Days’)
plt.legend()
plt.show()
(5 mark for correct code)
OR
import matplotlib.pyplot as pp
eng = [56,78,90,34]
sci = [65,77,54,32]
maths = [45,67,43,41]
pp.bar(eng,sci,maths)
pp.title(‘Subject Analysis’)
pp.xlabel(‘Marks’)
pp.ylabel(‘Subjects’)
pp.show()
(5 mark for correct code)
KENDRIYA VIDYALAYA SANGATHAN, JAIPUR REGION
FIRST PRE-BOARD EXAMINATION (Session 2023-24)
CLASS XII
INFORMATICS PRACTICES (065)
TIME: 03 HOURS M.M.: 70
General Instructions:
1. This question paper contains five sections, Section A to E.
2. All questions are compulsory.
3. Section A has 18 questions carrying 01 mark each.
4. Section B has 07 Very Short Answer type questions carrying 02 marks each.
5. Section C has 05 Short Answer type questions carrying 03 marks each.
6. Section D has 02 questions carrying 04 marks each.
7. Section E has 03 questions carrying 05 marks each.
8. All programming questions are to be answered using Python Language only

SECTION A
QUE MARK
S S
1 Which type of computer network formed from personal devices. 1
(A) LAN (B) MAN
(C) WAN (D) PAN
2 The information /art/work that exists in digital form is called________. 1
(A) e-work (B) e-asset
(C) digital property (D) e-property
3 Legal term to describe the right of creator of original creative or artistic work is 1
called_____.
(A) Copyright (B)Copyleft
(C) GPL (D) Trademark
4 Find the output for the below sql statement: 1
Select substr(“BoardExam@2021”, 4, 7);
(A) ardExam (B) dExam@2
(C) rdExam (D) rdExam@2
5 In column “Margin “contains the data set(2.00,2.00,NULL,4.00,NULL,3.00,3.00). 1
What will be the output of after the execution of the given query?
SELECT AVG(Margin) FROM SHOP;
(A) 2.9 (B) 2.8
(C) 2.00 (D) All of these
6 URL stands for 1
(A) Universal Resource Locator (B) Uniform Resource Locator
(C) Universal Range Limit (D) None of the above
7 To open a file c:\scores.csv for reading, we use _______ command. 1
(A) infile = open(“c:\scores.csv”, “r”)
(B) infile = open(“c:\\scores.csv”, “r”)
(C) infile = open(file = “c:\scores.csv”, “r”)
(D) infile = open(file = “c:\\scores.csv”, “r”)

8 Gopi Krishna is using a table Employee. It has the following columns: 1


Code, Name, Salary, Deptcode
He wants to display average salary department wise of those departments
which have more than six employees.he wrote the following command:
SELECT Deptcode, avg(Salary) FROM Employee ;
But he did not get the desired result. Which of the following is a correct query to
perform the given task?
(A) SELECT Deptcode, avg(Salary) FROM Employee WHERE count(*) > 6
GROUP BY Deptcode ;
(B) SELECT Deptcode, avg(Salary) FROM Employee HAVING count(*) > 6
GROUP BY Deptcode ;
(C) SELECT Deptcode, avg(Salary) FROM Employee GROUP BY Deptcode
WHERE count(*) > 6;
(D) SELECT Deptcode, avg(Salary) FROM Employee GROUP BY Deptcode
HAVING count(*) > 6;

9 Which MySQL function returns the week day name corresponding to Date value 1
supplied as argument.
(A) weekday() (B)dayname()
(C)dayofweek() (D)weekofday()
10 Given a Pandas series called p_series, the command which will display the last 1
4 rows is ________
(A) print (p_series.Tail(4)) (B) print (p_series.Tails(4))
(C) print (p_series.tail(4)) (D) print (p_series.Tails(4))
11 Which of the following is not MySQL Numeric Data Type? 1
(A) BIT(Size) (B) CHAR(Size)
(C) INTEGER(Size) (D) INT(Size)
12 what will be the output of following code: 1
import pandas as pd
a=pd.Series([2,3,4,5])
b=pd.Series([5,6,7,8,9])
c=a+b
print(c)
(A) (B) (C) (D) Error
0 7 0 7.0 0 7.0
1 9 1 9.0 1 9.0
2 11 2 11.0 2 11.0
3 13 3 13.0 3 13.0
4 0 4 0 4 NaN
dtype: float64 dtype: float64 dtype: float64
13 Stealingsomeone’sintellectualworkandrepresentingitasanotherperson’sworkisk 1
nownas .
(A) Phishing (B) Spamming
(C) plagiarism (D) hacking
14 Which of the following function is the correct syntax of LCASE() function? 1
(A) LCASE(row_name) (B) LCE(column_name)
(C) LCASE(str/column_name) (D) None of the above
15 Whichprotocolallowustohavevoicecallsovertheinternet? 1
(A) HTTP (B) VoIP
(C) VideoChat (D) SMTP
16 Theterm Intellectualpropertyrightscover 1
(A) Trademark (B) Copyright
(C) Patents (D) Allof these
Q17 and 18 are ASSERTION AND REASONING based questions. Mark
the correct choice as
i. Both A and R are true and R is the correct explanation for A
ii. Both A and R are true and R is not the correct explanation for A
iii. A is True but R is False
iv. A is false but R is True
17 Assertion (A): - Antivirus should be installed in our compute system. 1
Reasoning (R):- It is used to detect and remove viruses and other kinds of
malicious software from your computer or laptop.
18 Assertion (A): - Series is a one-dimensional labeled array capable of holding 1
data of any type Reasoning (R):- Series has both row and column values.

SECTION B
QUES MARKS
19 ExplainthetermsWebpageandHomePage. 2

OR

ExpandthefollowingtermsrelatedtoComputerNetworks:
a.SMTP b. POP c. FTP d. TCP
20 The python code written below has syntactical errors. Rewrite the correct code 2
and underline the corrections made.
IMPORT pandas as pd
df ={"name":["satish","rahul","arvind"],"exp(in months)":[14,41,31]}
df= pd.dataframe(df)
print(df)
21 Consider “Winners never quit”. Write the queries for the following tasks. 2

i. Write a command to display “quit”.


ii. Write a command to check the first occurrence of letter ‘n’

22 Giventwoseries S1and S2 2
S1
S
2
A 39 A 10
B 41 B 10
C 42 D 10
D 44 F 10
Find the output for following
python pandas statements?
a. S1[ :2]*100
b.S1*S2
23 What do you understand by digital footprint? What are the different types of 2
digital footprints?
24 Consider the following code and fill in the gaps to get the given output: 2

import _____________ as pd

s=pd.Series(______,_______)

print(____)

1 3
2 3
3 3
4 3
25 Define any two aggregate functions. 2

SECTION C
QUE MARK
S S
26 Basedontable Employeegivenhere, writesuitableSQLqueries forthefollowing: 3

i. Displaygenderwiseaveragesalary.
ii. Displaydesignationwisemaximumsalary.
iii. Dislaytotalnumberofemployeesineach Dept.

OR

Predict the output of the following queries based on the above table Employee:
i. SELECT LEFT (Name , 2) FROM Employee WHERE Gender = “F”;
ii. SELECT AVG(Salary) FROM Employee WHERE Dept = “Sales”;
iii. SELECT SUM(Salary) FROM Employee WHERE Designation =
“Clerk”;
27 WriteaPythoncodetocreateaDataFramewithcolumnheadingsas(stu_id,name,c 3
lass)and data labelsas (1,4,5,6)fromthelistgiven below:

L1=[[101,'Guru',10],[102,'Raj',9],[103,'Sam',12],[104,'Yuvraj',12]]
28 Write MySQL statements for the following: 3
i. To create a database named AUTOMOBILE.
ii. To create a table named VEHICLE based on the following
specification:

Column Name DataType Constraints


VehicleNumber INT Primary Key
VehicleName Char(40)
VehicleModel Char(50) UNIQUE
29 Samridh has recently changed his school so he is not aware of the people, but 3
someone is posting negative demeaning comments on his social media profile.
He is also getting repeated mails from unknown people. Every time he goes
online, he finds someone chasing him online. (i) Samridh is a victim of
___________. (ii) The action that Samridh should take to handle it. (iii)
..........................is a set of moral principles that governs the behavior of a group
or individual and regulates the use of computers.

OR

WhatdoyouunderstandbyNetEtiquettes?Explainanytwosuchetiquettes.
30 Consider the given DataFrame ‘Items’: 3
Name Price Quantity
0 CPU 7750 15
1 Watch 475 50
2 Key Board 225 25
3 Mouse 150 20
Write suitable Python statements for the following:
i) Add a column called Sale_Price which is 10% decreased value of Price
ii) Add a new item named “Printer” having price 8000 and Quantity as 10.
iii) Remove the column Quantity

SECTION D
QUES MARKS
31 ConsidertheTableCLUBgivenbelow: 4
COACH_ID COACHNAME AGE SPORTS DATOFAPP PAY SEX
1 KUKREJA 35 KARATE 1996-03-27 10000 M
2 RAVINA 34 KARATE 1997-01-20 12000 F
3 KARAN 34 SQUASH 1998-02-19 20000 M
4 TARUN 33 BASKETBALL 1998-01-01 15000 M

Answerthefollowingsbasedontheabovemysql table‘CLUB’
i. Writesqlquesrytodisplaytheaverage payfor karate coach
ii. Writesqlquerytodisplaymonthfordateofappointment’DATEOFAPP
iii. Writesqlquerytodisplaythe detailsofmalecoachinascendingorder oftheirage
iv. WriteSQLquerytodisplaygamewisemaximum payofall caoches.

32 Consider the following DataFrame, Class DF with row index St1, St2, St3, St4 4

Based on the above dataframe answer the followinsg:


A. Predict the output
i. ClassDF.T ii. ClasDF [ : : -2]
B. Write python statement to print Name,class and CGPA for Student St2 and St3

OR

write python Statement to print the name and class of students having CGPA more
than 9.0

SECTION E
QUES MARKS
33 Write suitable SQL query for the following: 5
i. Display 7 characters extracted from 7th left character onwards from the string ‘INDIA
SHINING’.
ii. Display the position of occurrence of string ‘COME’ in the string ‘WELCOME WORLD’.
iii. Round off the value 78.779 to 2 nd decimal place.
iv. Display the remainder of 149 divided by 6.
v. Remove all the expected leading and trailing spaces from a column userid of the
table ‘USERS’.

OR

Consider the following table TEACHER:


+-------+---------+------------------+-------+-----------------------
| TNo | TName | Dept | DOJ|
+-------+---------+-----------+-------+-----------------------
|1 | Tanu | CS | 05.09.2007 |
|2 | Sameer | MATHS | 10.09.2007|
|3 | Vineet | PHYSICS | 19.09.2014|
|4 | Sneh | BIO | 21.09.2014 |
|5 | Akshit | CHEM |18.09.2021 |
+-------+---------+------------------+-------+------------------
Help her in writing SQL queries to the perform the following task:
a) Insert a new record in the table having following values:
[6,'Abhinav','office',12.10.2023]
b) To change the value “CS” to “Computer Science” in subject column.
c) To remove the records of those teachers who belongs to physics department.
d) To add a new column Salary of suitable datatype.
e) To display records of “CS” department.
34 SHARMA Medicos Center has set up its new center in Delhi . It has four buildings as 5
shown in thediagramgiven below:

Distancebetween variousbuilding areasfollows:

Asanetwork expert, providethebest possibleanswer forthefollowing queries:

i. Suggestacablelayoutof connectionsbetweenthe buildings.


ii. Suggestthemost suitableplace(i.e. buildings)to housetheserverofthisorganization.
iii. Suggesttheplacementof the followingdevicewithjustification:
a) Repeater b)Hub/Switch
iv. Suggestasystem(hardware/software)topreventunauthorizedaccesstoorfromthenetwork.
v. Thecompanyis planningto linkitshead officesituatedinDelhi
withtheofficesinhillyareas.Suggestaway to connect it economically.
35 Generate random numbers from 1 to 70 and plot it on the histogram. Change the outline 5
color to black and the bar color should be yellow.

OR

Writepythoncodetoplotbarchartforsubjectwiseresultanalysisasshownbelow:
Alsogive suitablepythonstatementtosavethischartas‘Result.png’
KENDRIYA VIDYALAYA SANGATHAN, JAIPUR REGION
FIRST PRE-BOARD EXAMINATION (Session 2023-24)
CLASS XII
INFORMATICS PRACTICES (065)
MARKING SCHEME
TIME: 03 HOURS M.M.: 70
SECTION A
QUES MARKS
1 (D) PAN 1
2 (C)digital property 1
3 (A) Copyright 1
4 (D) rdExam@2 1
5 (B) 2.8 1
6 (B) Uniform Resource Locator 1
7 (B)infile = open(“c:\\scores.csv”, “r”) 1
8 (D) SELECT Deptcode, avg(Salary) FROM Employee GROUP BY Deptcode 1
HAVING count(*) > 6;
9 (B)dayname() 1
10 (C) print(p_series.tail(4)) 1
11 (B) CHAR(Size) 1
12 (C) 1
0 7.0
1 9.0
2 11.0
3 13.0
4 NaN
dtype: float64
13 (C) plagiarism 1
14 (C) LCASE(str/column_name) 1
15 (B) VoIP 1
16 (D)Allof these 1
17 i. Both A and R are true and R is the correct explanation for A 1
18 iii. A is True but R is False 1

SECTION B
QUES MARKS
19 WebPage:AWebPageisapartofawebsiteandiscommonlywritteninHTML.Itcan be 2
accessedthroughaweb browser.
HomePage: Itisthe firstweb pageyouseewhenyouvisit awebsite.
1markforcorrectexplanationofeachterm
OR
a. SMTP:SimpleMailTransfer Protocol
b. POP:PointtoPointProtocol
c. FTP:FileTransferProtocol
d. TCP: Transmission Control Protocol
½marksforeachcorrectfullform
20 import pandas as pd 2
df ={"name":["satish","rahul","arvind"],"exp(in months)":[14,41,31]}
df= pd.DataFrame(df)
print(df)
21 1. selectsubstr(“Winners never quit”,-4); 2
OR
select substr(“Winners never quit”,14);
You can also use mid function as well.
2. Select instr(“Winners never quit”,’n’)
22 a. A 3900 2
B 4100
b. A 390
B 410
C NaN
D 440
F NaN
23 A digital footprint is data that is left behind when users have been online. There 2
are two types of digital footprints which are passive and active.
24 import pandas as pd 2
s=pd.Series(3,index=[1,2,3,4])
print(s)
25 1 mark for each aggregate function 2

SECTION C
QUES MARKS
26 i. SELECTGENDER,AVG(SALARY)FROMEMPLOYEEGROUPBYGENDER; 3
ii. SELECTDESIGNATION,MAX(SALARY)FROMEMPLOYEEGROUPBYDESIGNATION;
iii. SELECTDEPT,COUNT(*)FROMEMPLOYEE GROUPBYDEPT;
OR
i. LEFT(Name,2)
Su
Ne
Ne
ii. AVG(Salary)
21500
iii. SUM(Salary)
32000
27 import pandasaspd 3
L1=[[101,'Guru',10],[102,'Raj',9],[103,'Sam',12],[104,'Yuvraj',12]]
df=pd.DataFrame(L1,columns=['stu_id','Name','class'])

1markforeachcorrectpythonstatement
28 (i) Create database AUTOMOBILE 3
(ii) Create table vehicle (vehiclenumberint primary key, vehiclename char(40),
vehiclemodel char(50))
29 i. Cyber stalking 3
ii. He should bring to the notice of his parents and school authorities.
iii.Computer ethics
OR
Net Etiquettes refers to the proper manners and behavior we need to exhibit while being
online.Theseinclude:
1. Nocopyrightviolation:weshouldnotusecopyrightedmaterialswithoutthepermissionof the
creator or owner. We should give proper credit to owners/creators of open
sourcecontentwhen using them.
2. Avoid cyber bullying: Avoid any insulting, degrading or intimidating
onlinebehaviorlikerepeated
posting of rumours, giving threats
online,postingthevictim’spersonalinformation,
orcommentsaimed topubliclyridicule avictim.Oranyother
relevantanswer.
1½ marksfordefinitions ofNet Etiquettes
1½mark eachforthe examplewithexplanation
30 i) Items['Sale_Price']=0.90 * Items[‘Price’] 3
ii) Items.loc['4']=[“Printer”, 8000, 10]
iii) Items=Items.drop('Quantity', axis=1)
1 mark for each correct statement

SECTION D
QUES MARKS
31 i. SELECTAGV(PAY)FROMCLUBWHERESPORTS=’KARATE’; 4
ii. SELECTMONTH(DATEOFAPP)FROMCLUB;1mark
for eachcorrectquery
iii. SELECT*FROMCLUBWHERESEX=’M’ORDERBYAGEASC;
OR
iv. SELECTSPORTS,MAX(PAY)ROMCLUBGROUPBYSPORTS;
2mark for eachcorrectquery
32 A. 1 mark for each correct answer 4
B. ClassDF.loc[St2:St3 , [‘Name’,’Class’,CGPA’]
OR
ClassDF[[‘Name’,’Class’][ClassDF.CGPA>9.0]
2 marks for each correct answer

SECTION E
S M
i. select mid('INDIA SHINING',7,7);
ii. select INSTR('WELCOME WORLD','COME');
iii. select round(78.779,2);
iv. select mod(149,6);
v. select trim(userid) from users; (1 mark for each correct query )
OR
a) insert into employee values(6,'Abhinav','office',’12.10.2023’)
b) Update employee set dept=”CS” where dept=”Computer Science”
c) Delete from employee where dept=’physics’
d) Alter table employee add salary decimal
e) Select * from employee where dept=”CS”
i. 1markforcorrect layout
ii. ResearchLab
iii. Repeater:BetweenAccountsandStore,Hub/Switchineachblock
iv. Firewall
v. RadioWave
1markforeachcorrect answerorforanyotherrelevantanswer
import matplotlib.pyplot as m
import numpy as np
x=np.random.randn(70)
m.hist(x,20,edgecolor=”black”,facecolor=”yellow”)
m.show()
OR
import matplotlib.pyplot as
pltsub=['ENGLISH','ACCOUNTS','BST','ECONOMICS','IP']per=[85,98,70,82,100]
plt.bar(sub,per,color='green',align='center') #1 markplt.xlabel("SUBJECT")
plt.ylabel("PERCENTAGE")plt.title("SUBJECTWISERESULTANALYSIS")
plt.show()plt.savefig(‘Result.png’)
Page: 1/7
KENDRIYA VIDYALAYA SANGATHAN JAIPUR REGION
FIRST PRE-BOARD EXAMINATION (Session 2023-24)
CLASS XII
INFORMATICS PRACTICES (065)
TIME: 03 HOURS M.M.: 70

General Instructions:
1. This question paper contains five sections, Section A to E.
2. There are internal choices in Q. No. 19, 26,29,32 (only part iii), 33 and 35
3. Section A has 18 questions carrying 01 mark each.
4. Section B has 07 Very Short Answer type questions carrying 02 marks each.
5. Section C has 05 Short Answer type questions carrying 03 marks each.
6. Section D has 02 questions carrying 04 marks each.
7. Section E has 03 questions carrying 05 marks each.

SECTION A
Q M
1 Which device connects an organization's network with the outside world of the 1
Internet?
a) Hub b) Modem
c) Gateway d) Repeater
2 E-waste contains Heavy metals such as ________ and _____which are highly toxic 1
when ingested.
a) Hydrogen and Mercury
b) Lead and Argon
c) Lead and Mercury
d) Hydrogen and Argon
3 It is an act of copying another person’s data idea, words or work and pretended that 1
they are our own.
a) Copyright
b) Virus
c) Plagiarism
d) IPR
4 Imagine you work as a data analyst for a retail company. The company provides you 1
with a large dataset of sales transactions in a CSV file. Your task is to import this data
and perform various data manipulation and analysis operations. Which Pandas
method should you use to read this CSV file and load it into a DataFrame for your
analysis?
a) Read_CSV() b) import_data()
c) load_csv() d) read_csv()
5 Predict the output of following query: 1
Select mod(12,3);
a) 2 b) 4
c) 0 d) The query will produce error
6 ‘P’ in IPR stands for 1
a) Proprietary b) Platform
c) Patent d) Property
7 What does CSV stand for in the context of data storage? 1
a) Column Separated Value
b) Class Separated Value
c) Comma Separated Value
d) Comma Segregated Value
8 A Database Administrator needs to display the average pay of workers from each 1
departments with more than five employees. Which SQL query is correct for this task?
Page: 2/7
a) SELECT DEPT, AVG(SAL) FROM EMP WHERE COUNT(*) > 5 GROUP BY
DEPT;
b) SELECT DEPT, AVG(SAL) FROM EMP HAVING COUNT(*) > 5 GROUP BY
DEPT;
c) SELECT DEPT, AVG(SAL) FROM EMP GROUP BY DEPT WHERE COUNT(*) >
5;
d) SELECT DEPT, AVG(SAL) FROM EMP GROUP BY DEPT HAVING COUNT(*) >
5;
9 The mid( ) function in MySQL is an example of _______________. 1
a) Math function b) Text function
c) Date Function d) Aggregate Function
10 Which command is used to display the last 3 rows from a Pandas Series named NP? 1
a) NP.Tail() b) NP.tail(3)
c) NP.TAIL(3) d) All of the above
11 In SQL, which of the following is an invalid data type? 1
a) Date b) Integer
c) Varchar d) Month
12 Which attribute is not used with the Dataframe? 1
a) Size b) column
c) Empty d) type
13 When a software company's server is unethically accessed to obtain sensitive info 1
and it is unreadable at companies end, the attacker demands payment to prevent the
release of that information, it's known as:
a) Phishing b) Identity Theft
c) Plagiarism d) Ransomware
14 Which of the following function is the correct syntax of LCASE() function? 1
a) LCASE(row_name) b) LCE(column_name)
c) LCASE(str/column_name) d) None of the above
15 Incognito mode of browser is used for: 1
a) public browsing b) Hides contents from web server
c) private browsing d) save cookies
16 While surfing on Internet if your geo location is turned on, than it makes 1
a) Active digital footprint b) Passive digital footprint
c) Active e footprint d) Passive e footprint
Q17 and 18 are ASSERTION AND REASONING based questions. Mark
the correct choice as
i. Both A and R are true and R is the correct explanation for A
ii. Both A and R are true and R is not the correct explanation for A
iii. A is True but R is False
iv. A is false but R is True
17 Assertion (A): A firewall is a device that allows unrestricted data flow in a network. 1
Reasoning(R): It serves as a barrier between a private internal network and external
networks, controlling and monitoring incoming and outgoing network traffic.
18 Assertion (A):- df.loc(False) function can be used to find the values where index value 1
is False. Reason (R):- Boolean indexing is a type of indexing and can be used to
retrieve the data

SECTION B
QUES MARK
S
19 You are tasked with creating a website for a small business. Outline the steps 2
you would take to launch the website. Provide at least two necessary steps.
OR
You are evaluating the performance of different web browsers for a company's
Page: 3/7
internal web-based application. Provide any two criteria you would use to
assess the browsers' performance.
20 The python code written below has syntactical errors. Rewrite the correct code 2
and underline the corrections made.

import pandas as pt
data = {'Name': ['Ramesh Pillai', 'Priya Nair', 'Suresh Menon'],
'Age': [28, 32, 26],
'City': ['Mcleodganj', 'Jalandhar', 'Sanchor']}
df = pd.DataFrame(data)
print(df.head)
21 Consider the given MySQL query: SELECT NOW(); 2
It returns the current Date and Time. Modify this query with help of suitable date
functions to :
A. Return the month from the current date and time.
B. Retrieve the day of the week for the current date and time.
22 Predict the output of python code based on series 2
import pandas as pd
temp = pd.Series([28, 32, 29, 35, 30, 31, 33])
ft = temp[temp > 30]
print(ft)
23 As a YouTube content creator, can you use background music for free without 2
worrying about copyright strike? If so, what type of licence is needed for that
piece of media?
24 Complete the given Python code to create a Pandas Series named "cu" with the 2
top five central universities in India and their respective states as data. Then,
display only those universities which are from the state of "Delhi."
import pandas as pd
cu_names = ['DU', 'JNU', 'BHU', 'AMU', 'JMI']
cu_states = ['Delhi', 'Delhi', UP', 'UP', 'Delhi']
cu = pd.Series(__________)
print(___________)
25 What is the difference between Aggregate Function and Scaler Function in 2
MySQL? Provide the name of one function from each.

SECTION C
QUES MARK
S
26 Consider the SQL table "PRODUCT_SALES" with the following data: 3
| Product | Segment | Region | SalesQ1 | SalesQ2 |
| P1 | High | A | 25000 | 32000 |
| P2 | Medium | B | 18000 | 20000 |
| P3 | Low | A | 8000 | 9000 |
| P4 | High | C | 35000 | 38000 |
| P5 | Medium | B | 22000 | 25000 |
| P6 | Low | C | 5000 | 5500 |
Write suitable SQL queries for the following:
1. Display the region-wise average sales in the first quarter.
2. Display the segment-wise highest sales in the second quarter.
3. Display the records in descending order of sales in the second quarter.
OR
Predict the output of the following queries based on the table
"PRODUCT_SALES" given above:
1. SELECT LEFT(Segment, 2) FROM PRODUCT_SALES WHERE Region =
'A';
Page: 4/7
2. SELECT (SalesQ2 - SalesQ1) / 2 AS Sale2 FROM PRODUCT_SALES
WHERE Segment = 'High';
3. SELECT SUM(SalesQ1) AS "TOTAL” FROM PRODUCT_SALES WHERE
Region = 'B';
27 You are tasked with creating a DataFrame to store information about gaming 3
apps available on various digital platforms. The DataFrame should have three
columns: Name, Genre, Type (Free or Paid), and Downloads.
To achieve this, you have the following data:
Name Genre Type Downloads(mil)
1 Call of Duty: Warzone FPS Free 20
2 The Witcher 3: Wild Hunt RPG Paid 5
3 Candy Crush Saga Puzzle Free 65
4 Among Us Arcade Free 50
5 Minecraft Sandbox Paid 10
Now create a dataframe with a dictionary of Series and index should be from 1
to 5.
28 Write MySQL statements for the following: 3
A. To use a database named Pets.
B. To see all the tables inside the database.
C. To see the structure of the table named horse.
29 Nisha loves online shopping and frequently makes purchases on various e- 3
commerce websites. One day, she received an email with an incredible
discount offer on a popular shopping platform. Excited about the deal, she
clicked on the provided link and made a payment. However, after the
transaction, she received neither a confirmation nor the product she ordered.
A few days later, she realized that the website was fake, and her money was
gone. She also found unauthorized transactions on her credit card. Distressed
and frustrated, Nisha decided to seek legal action.
Answer the following questions:
1. Identify the type of cybercrime Nisha is a victim of.
2. Is there a specific branch/division of police in which she can report the crime?
3. Suggest Nisha two precautionary measures she should take in the future
while shopping online to avoid falling victim to such situations.
OR
What are the positive impacts of ICT on physical and mental health? Describe
any two of such impacts.
30 Consider the given DataFrame ‘Anime’: 3
Name Genre Eps Year of Creation
1 Naruto Shounen 220 2002
2 One Piece Shounen 1300 1999
3 Attack on Titan Action 75 2013
4 Dragon Ball Z Shounen 291 1989
Write suitable Python statements for the following:
1. Add a row with the following data: [“Death Note“,“Mystery“,37,2006].
2. Rename the column ‘Eps’ to ‘Episodes’ and ‘Year of Creation‘ to ‘Year‘.
3. Drop the column ‘Genre‘.

SECTION D
QUES MARK
S
31 AlakhNiranjan is responsible for managing a database in a financial company. 4
The company stores financial transaction data in a table named FINE_TRNC.
Alakh needs your assistance in writing SQL queries to retrieve specific
information from the table. The attributes of the table are:
TransactionDate,TransactionAmount.
Page: 5/7
1. Write a query to display the date of the most recent transaction.
2. Write a query to retrieve the average transaction amount for the month of
June.
3. Write a query to list the maximum amount for the transaction that occurred in
the month of December.
4. Write a query to count the total number of transactions that took place in the
year 2023.
32 Riya, a Data Analyst working for a film studio, has created a DataFrame named 4
'movie_revenue_df' to store the revenue data of movies released by Viacom 18
in the year 2022. The DataFrame looks like this:
Movie Revenue (in crores)
A. GangubaiKathiawadi 125
B. The Kashmir Files 340
C. Bhediya 75
D. JugJuggJiyo 250
E. Bachchhan Pandey 120
An intern is working with her and has a few doubts. As Riya is busy with
analysis work. You answer on her behalf.
(i) Predict the output of the following python statement:
a. print(movie_revenue_df[‘Revenue (in crores)’].dtypes)
b. print(movie_revenue_df.iloc[2,0])
(ii) Delete the Second last row from the DataFrame.
(iii) Find out the total revenue.
OR(Option for part iii only)
Write Python statement to export the DataFrame to a CSV file named
“hit_movies_2022.csv” in the directory named ‘PMDB’ which is inside the
present working directory(PWD) of the project.

SECTION E
QUES MARK
S
33 Write suitable SQL queries for the following: 5
1. Write an SQL query to calculate 3 raised to the power of 4.
2. To round off the value 1969.5538 without any decimal part
3. Display the current date.
4. Convert the string 'After the test,take some rest’ to uppercase:
5. Return the length of the string 'To chaloshurukartehain'.
OR
Take a look at the table structure of the table ‘IndianAlbums’ and `Artist_Info`
IndianAlbums Artist_Info
Attribute Data Type Attribute Data Type

AlbumID INT ArtistID INT

AlbumName VARCHAR(100) ArtistNam VARCHAR(100)


e

ArtistID INT
Nationalit VARCHAR(50)
y
ReleaseYear INT
Page: 6/7

Genre VARCHAR(50)

Sales DECIMAL(10,
2)

Language VARCHAR(50)

Write SQL queries to perform the following tasks:


1. Insert a new record into the `IndianAlbums` table with the following details:
- AlbumName: "Lagaan"
- ReleaseYear: 2001
- Genre: "Soundtrack"
- Sales: 5000000
- Language: "Hindi"
2. Update the `IndianAlbums` table to modify the sales of the album with
`AlbumID` 3 to 1000000.
3. Delete the record of the album named "Dil Se" from the `IndianAlbums` table.
4. Alter the table structure of `IndianAlbums` to add a new column named
"Language" of data type VARCHAR(50).
5. Select all albums released in the year 1990 or later, and for each album,
retrieve the album name, release year, genre, and the name of the artist.
34 RajatParivahanUpkaramPvt. Ltd. has established its presence in two cities: 5
Kaithal and Sirsa. The Kaithal city office has 4 blocks named K1, K2, K3 and
K4 and Sirsa is a franchise 400 kms away. The tables given below show the
distance between different blocks and the number of computers in each block.

Distance
(in m) K1 K2 K3 K4

K1 0 70 150 60

50
K2 70 0 130

K3 150 130 0 100

K4 60 50 100 0

Block No. of Workstations (Computers)

K1 50

K2 150

K3 30

K4 70
Page: 7/7

The company is planning to form a network by joining these blocks and two
offices. Answer the following questions to help them out:

1. Suggest the most appropriate block for placing the network server out of four
blocks.

2. To ensure efficient communication among the three cities, propose a


suitable network topology and provide a network diagram illustrating the
structure.

3. Please specify which city branch you choose as the LAN and why?.

4. Suggest the optimal placem


placement of the following devices:
- Repeater
- Firewall

5. Company is planning to use VPN. Expand the term VPN and clarify its
significance within this network setup.
35 Month Wise sale of iphone 14 is given below: 5
data = { "Month": ["Sep22", "Oct22", "Nov22", "Dec22", "Jan23", "Feb23",
"Mar23", "Apr23"], "Sales": [1000000, 1200000, 1500000, 2000000, 1800000,
1700000, 1600000, 1500000] }
Draw a line plot based on this data to know the trend of sales in two quarters (8
months). Use appropriate customisat
customisations.
OR
Write suitable Python code to create a Bar Chart showcasing the medal
talley of top of countries in the asia cup 2023.

# medal count
medals = [88, 60, 58, 43, 35]
KENDRIYA VIDYALAYA SANGATHAN, JAIPUR REGION
FIRST PRE-BOARD EXAMINATION (Session 2023-24)
CLASS XII
INFORMATICS PRACTICES (065)
MARKING SCHEME
TIME: 03 HOURS M.M.: 70
General Instructions:
1. This question paper contains five sections, Section A to E.
2. All questions are compulsory.
3. Section A has 18 questions carrying 01 mark each.
4. Section B has 07 Very Short Answer type questions carrying 02 marks each.
5. Section C has 05 Short Answer type questions carrying 03 marks each.
6. Section D has 02 questions carrying 04 marks each.
7. Section E has 03 questions carrying 05 marks each.
8. All programming questions are to be answered using Python Language only

SECTION A
Q M
1 Which device connects an organization's network with the outside world of the 1
Internet?
a) Hub
b) Modem
c) Gateway
d) Repeater
2 E-waste contains Heavy metals such as ________ and _____which are highly toxic 1
when ingested.
a) Hydrogen and Mercury
b) Lead and Argon
c) Lead and Mercury
d) Hydrogen and Argon
3 It is an act of copying another person’s data idea, words or work and pretended that 1
they are our own.
a) Copyright
b) Virus
c) Plagiarism
d) IPR
4 Imagine you work as a data analyst for a retail company. The company provides you 1
with a large dataset of sales transactions in a CSV file. Your task is to import this data
and perform various data manipulation and analysis operations. Which Pandas
method should you use to read this CSV file and load it into a DataFrame for your
analysis?
a) Read_CSV()
b) import_data()
c) load_csv()
d) read_csv()
5 Predict the output of following query: 1
Select mod(12,3);
a) 2 b) 4
c) 0 d) The query will produce error
6 ‘P’ in IPR stands for 1
a) Proprietary b) Platform
c) Patent d) Property
7 What does CSV stand for in the context of data storage? 1
a) Column Separated Value
b) Class Separated Value
c) Comma Separated Value
d) Comma Segregated Value
8 A Database Administrator needs to display the average pay of workers from each 1
departments with more than five employees. Which SQL query is correct for this task?
a) SELECT DEPT, AVG(SAL) FROM EMP WHERE COUNT(*) > 5 GROUP BY
DEPT;
b) SELECT DEPT, AVG(SAL) FROM EMP HAVING COUNT(*) > 5 GROUP BY
DEPT;
c) SELECT DEPT, AVG(SAL) FROM EMP GROUP BY DEPT WHERE COUNT(*) >
5;
d) SELECT DEPT, AVG(SAL) FROM EMP GROUP BY DEPT HAVING COUNT(*)
> 5;
9 The mid( ) function in MySQL is an example of _______________. 1
a) Math function b) Text function
c) Date Function d) Aggregate Function
10 Which command is used to display the last 3 rows from a Pandas Series named NP? 1
a) NP.Tail()
b) NP.tail(3)
c) NP.TAIL(3)
d) All of the above
11 In SQL, which of the following is an invalid data type? 1
a) Date
b) Integer
c) Varchar
d) Month
12 Which attribute is not used with the Dataframe? 1
a) Size b) column
c) Empty d) type
13 When a software company's server is unethically accessed to obtain sensitive info 1
and it is unreadable at companies end, the attacker demands payment to prevent the
release of that information, it's known as:
a) Phishing
b) Identity Theft
c) Plagiarism
d) Ransomware
14 Which of the following function is the correct syntax of LCASE() function? 1
a) LCASE(row_name) b) LCE(column_name)
c) LCASE(str/column_name) d) None of the above
15 Incognito mode of browser is used for: 1
a) public browsing b) Hides contents from web server
c) private browsing d) save cookies
16 While surfing on Internet if your geo location is turned on, than it makes 1
a) Active digital footprint b) Passive digital footprint
c) Active e footprint d) Passive e footprint
Q17 and 18 are ASSERTION AND REASONING based questions. Mark
the correct choice as
i. Both A and R are true and R is the correct explanation for A
ii. Both A and R are true and R is not the correct explanation for A
iii. A is True but R is False
iv. A is false but R is True
17 Assertion (A): A firewall is a device that allows unrestricted data flow in a network. 1
Reasoning(R): It serves as a barrier between a private internal network and external
networks, controlling and monitoring incoming and outgoing network traffic.

Ans. iv
18 Assertion (A):- df.loc(False) function can be used to find the values where index value 1
is False. Reason (R):- Boolean indexing is a type of indexing and can be used to
retrieve the data
Ans. i

SECTION B
QUES MARK
S
19 You are tasked with creating a website for a small business. Outline the steps 2
you would take to launch the website. Provide at least two necessary steps.
Ans.
● Define the Purpose
● Choose a Domain Name
● Select a Hosting Provider
● Design and Develop the Website
OR
You are evaluating the performance of different web browsers for a company's
internal web-based application. Provide any two criteria you would use to
assess the browsers' performance.
Ans.
● Page Load Speed
● Compatibility with Web Standards
● Security Features
● Memory Usage
● Ease of Customization like availability of add-ons and extensions.
20 The python code written below has syntactical errors. Rewrite the correct code 2
and underline the corrections made.
import pandas as pt
data = {'Name': ['Ramesh Pillai', 'Priya Nair', 'Suresh Menon'],
'Age': [28, 32, 26],
'City': ['Mcleodganj', 'Jalandhar', 'Sanchor']}
df = pd.DataFrame(data)
print(df.head)

Ans.
Correct Code:
import pandas as pd
data = {'Name': ['Ramesh Pillai', 'Priya Nair', 'Suresh Menon'],
'Age': [28, 32, 26],
'City': ['Mcleodganj', 'Jalandhar', 'Sanchor']}
df = pd.DataFrame(data) # use pd instead of pt
print(df.head()) #head() instead of head
21 Consider the given MySQL query: SELECT NOW(); 2
It returns the current Date and Time. Modify this query with help of suitable date
functions to :
A. Return the month from the current date and time.
B. Retrieve the day of the week for the current date and time.

Ans.
A. SELECT MONTH(NOW()) AS current_month;
B. SELECT DAYNAME(NOW()) AS current_day_of_week;
22 Predict the output of python code based on series 2
import pandas as pd
temp = pd.Series([28, 32, 29, 35, 30, 31, 33])
ft = temp[temp > 30]
print(ft)
Ans.
1 32
3 35
5 31
6 33
dtype: int64
23 As a YouTube content creator, can you use background music for free without 2
worrying about copyright strike? If so, what type of licence is needed for that
piece of media?
Ans.
Yes. CC or Creative Commons License.
24 Complete the given Python code to create a Pandas Series named "cu" with the 2
top five central universities in India and their respective states as data. Then,
display only those universities which are from the state of "Delhi."

import pandas as pd
cu_names = ['DU', 'JNU', 'BHU', 'AMU', 'JMI']
cu_states = ['Delhi', 'Delhi', UP', 'UP', 'Delhi']
cu = pd.Series(__________)
print(___________)

Ans.
import pandas as pd
cu_names = ['DU', 'JNU', 'BHU', 'AMU', 'JMI']
cu_states = ['Delhi', 'Delhi', UP', 'UP', 'Delhi']
cu = pd.Series(cu_names,index=cu_states)
print(cu['Delhi'])
25 What is the difference between Aggregate Function and Scaler Function in 2
MySQL? Provide the name of one function from each.
Ans.
- Aggregate functions operate on a group of values and return a single result
(e.g., SUM, AVG, COUNT etc).
- Scalar functions work on individual values and return a modified individual
value (e.g., UPPER, LENGTH, NOW,MOD,POW etc).

SECTION C
QUES MARK
S
26 Consider the SQL table "PRODUCT_SALES" with the following data: 3

| Product | Segment | Region | SalesQ1 | SalesQ2 |


| P1 | High | A | 25000 | 32000 |
| P2 | Medium | B | 18000 | 20000 |
| P3 | Low | A | 8000 | 9000 |
| P4 | High | C | 35000 | 38000 |
| P5 | Medium | B | 22000 | 25000 |
| P6 | Low | C | 5000 | 5500 |

Write suitable SQL queries for the following:


1. Display the region-wise average sales in the first quarter.
2. Display the segment-wise highest sales in the second quarter.
3. Display the records in descending order of sales in the second quarter.

Ans.
1.
SELECT Region, AVG(SalesQ1) AS AvgSalesQ1
FROM PRODUCT_SALES
GROUP BY Region;

2.
SELECT Segment, MAX(SalesQ2) AS HighestSalesQ2
FROM PRODUCT_SALES
GROUP BY Segment;

3.
SELECT *
FROM PRODUCT_SALES
ORDER BY SalesQ2 DESC;

OR
Predict the output of the following queries based on the table
"PRODUCT_SALES" given above:
1. SELECT LEFT(Segment, 2) FROM PRODUCT_SALES WHERE Region =
'A';
2. SELECT (SalesQ2 - SalesQ1) / 2 AS Sale2 FROM PRODUCT_SALES
WHERE Segment = 'High';
3. SELECT SUM(SalesQ1) AS "TOTAL” FROM PRODUCT_SALES WHERE
Region = 'B';

Ans.
1. | LEFT(Segment, 2) |
| Hi |
| Lo |

2.
| Sale2 |
| 3500 |
| 1500 |

3.
| TOTAL |
| 40000 |
27 You are tasked with creating a DataFrame to store information about gaming 3
apps available on various digital platforms. The DataFrame should have three
columns: Name, Genre, Type (Free or Paid), and Downloads.

To achieve this, you have the following data:


Name Genre Type Downloads(mil)
1 Call of Duty: Warzone FPS Free 20
2 The Witcher 3: Wild Hunt RPG Paid 5
3 Candy Crush Saga Puzzle Free 65
4 Among Us Arcade Free 50
5 Minecraft Sandbox Paid 10

Now create a dataframe with a dictionary of Series and index should be from 1
to 5.

Ans.
import pandas as pd
data =
{
'Name': pd.Series(['Call of Duty: Warzone', 'The Witcher 3: Wild Hunt',
'Candy Crush Saga', 'Among Us', 'Minecraft']),
'Genre': pd.Series(['FPS', 'RPG', 'Puzzle', 'Arcade', 'Sandbox']),
'Type': pd.Series(['Free', 'Paid', 'Free', 'Free', 'Paid']),
'Downloads(mil)': pd.Series([2000000, 500000, 10000000, 500000000,
10000000])
}
df_game = pd.DataFrame(data, index=range(1, 6))
print(df_game)
28 Write MySQL statements for the following: 3
A. To use a database named Pets.
B. To see all the tables inside the database.
C. To see the structure of the table named horse.
Ans.
A. USE Pets;
B. SHOW TABLES;
C. DESCRIBE horse;
29 Nisha loves online shopping and frequently makes purchases on various e- 3
commerce websites. One day, she received an email with an incredible
discount offer on a popular shopping platform. Excited about the deal, she
clicked on the provided link and made a payment. However, after the
transaction, she received neither a confirmation nor the product she ordered.

A few days later, she realized that the website was fake, and her money was
gone. She also found unauthorized transactions on her credit card. Distressed
and frustrated, Nisha decided to seek legal action.

Questions:
1. Identify the type of cybercrime Nisha is a victim of.
2. Is there a specific branch/division of police in which she can report the crime?
3. Suggest Nisha two precautionary measures she should take in the future
while shopping online to avoid falling victim to such situations.

Ans.
1. Nisha is a victim of Online Shopping Fraud and Phishing.
2. She can report the crime to the Cyber Crime Division of the local police.
3. Nisha should verify the authenticity of discount offers in emails and
only make purchases on trusted and verified e-commerce websites.
Additionally, she should enable two-factor authentication for her online
payment methods to enhance security.
OR
What are the positive impacts of ICT on physical and mental health? Describe
any two of such impacts.

Ans.
1. Improved Access to Medical Information: ICT provides easy access to
health-related information, empowering individuals to make informed decisions
about their well-being.
2. Telehealth Services: ICT enables remote consultations with healthcare
professionals, increasing healthcare accessibility, especially in remote areas.
3. Mental Health Apps: ICT supports mental health with apps and platforms
offering therapy and coping tools for managing stress and anxiety.
4. Health Tracking Devices: Wearable devices and apps help monitor physical
activity and vital signs, promoting overall wellness.
5. Health Education: ICT aids in health education and awareness campaigns,
promoting healthier lifestyle choices and preventive care.
30 Consider the given DataFrame ‘Anime’: 3
Name Genre Eps Year of Creation
1 Naruto Shounen 220 2002
2 One Piece Shounen 1300 1999
3 Attack on Titan Action 75 2013
4 Dragon Ball Z Shounen 291 1989

Write suitable Python statements for the following:


1. Add a row with the following data: [“Death Note“,“Mystery“,37,2006].
2. Rename the column ‘Eps’ to ‘Episodes’ and ‘Year of Creation‘ to ‘Year‘.
3. Drop the column ‘Genre‘.

Ans.
# 1. Add a row using loc
anime_df.loc[4] = ['Death Note', 'Mystery', 37, 2006]

# 2. Rename columns
anime_df.rename(columns={'Episodes': 'Eps', 'Year of Creation': 'Year'},
inplace=True)

# 3. Drop the 'Genre' column


anime_df.drop(columns=['Genre'], inplace=True)

SECTION D
QUES MARK
S
31 Alakh Niranjan is responsible for managing a database in a financial company. 4
The company stores financial transaction data in a table named FINE_TRNC.
Alakh needs your assistance in writing SQL queries to retrieve specific
information from the table. The attributes of the table are:
TransactionDate,TransactionAmount.

1. Write a query to display the date of the most recent transaction.


2. Write a query to retrieve the average transaction amount for the month of
June.
3. Write a query to list the maximum amount for the transaction that occurred in
the month of December.
4. Write a query to count the total number of transactions that took place in the
year 2023.

Ans.
1. SELECT MAX(TransactionDate) FROM FINE_TRNC;
2. SELECT AVG(TransactionAmount) FROM FINE_TRNC
WHERE MONTH(TransactionDate) = 6;
3. SELECT MAX(TransactionAmount) FROM FINE_TRNC
WHERE MONTH(TransactionDate) = 12;
4. SELECT COUNT(*) FROM FINE_TRNC
WHERE YEAR(TransactionDate) = 2023;
32 Riya, a Data Analyst working for a film studio, has created a DataFrame named 4
'movie_revenue_df' to store the revenue data of movies released by Viacom 18
in the year 2022. The DataFrame looks like this:
Movie Revenue (in crores)
A. Gangubai Kathiawadi 125
B. The Kashmir Files 340
C. Bhediya 75
D. JugJugg Jiyo 250
E. Bachchhan Pandey 120
An intern is working with her and has a few doubts. As Riya is busy with
analysis work. You answer on her behalf.
(i) Predict the output of the following python statement:
a. print(movie_revenue_df[‘Revenue (in crores)’].dtypes)
b. print(movie_revenue_df.iloc[2,0])
(ii) Delete the Second last row from the DataFrame.
(iii) Find out the total revenue.
OR (Option for part iii only)
Write Python statement to export the DataFrame to a CSV file named
“hit_movies_2022.csv” in the directory named ‘PMDB’ which is inside the
present working directory(PWD) of the project.

Ans.
(i)
a. int64
b. Bhediya
(ii) movie_revenue_df = movie_revenue_df.drop(movie_revenue_df.index[-3])

(iii)
total_revenue = 0
for label, value in movie_revenue_df['Revenue (in crores)'].iteritems():
total_revenue += value
OR
(iii) movie_revenue_df.to_csv('PMDB/hit_movies_2022.csv', index=False)

SECTION E
QUES MARK
S
33 Write suitable SQL queries for the following: 5
1. Write an SQL query to calculate 3 raised to the power of 4.
2. To round off the value 1969.5538 without any decimal part
3. Display the current date.
4. Convert the string 'After the test,take some rest’ to uppercase:
5. Return the length of the string 'To chalo shuru karte hain'.

Ans.
1. SELECT POW(3, 4);
2. SELECT ROUND(1969.5538, 0);
3. SELECT CURDATE();
4. SELECT UPPER('After test,take rest');
5. SELECT LENGTH('To chalo shuru karte hain');
OR
Take a look at the table structure of the table ‘IndianAlbums’ and `Artist_Info`

IndianAlbums Artist_Info
Attribute Data Type Attribute Data Type

AlbumID INT ArtistID INT


AlbumName VARCHAR(100) ArtistNam VARCHAR(100)
e

ArtistID INT
Nationalit VARCHAR(50)
y
ReleaseYear INT

Genre VARCHAR(50)

Sales DECIMAL(10,
2)

Language VARCHAR(50)

Write SQL queries to perform the following tasks:

1. Insert a new record into the `IndianAlbums` table with the following details:
- AlbumName: "Lagaan"
- ReleaseYear: 2001
- Genre: "Soundtrack"
- Sales: 5000000
- Language: "Hindi"

2. Update the `IndianAlbums` table to modify the sales of the album with
`AlbumID` 3 to 1000000.

3. Delete the record of the album named "Dil Se" from the `IndianAlbums` table.

4. Alter the table structure of `IndianAlbums` to add a new column named


"Language" of data type VARCHAR(50).

5. Select all albums released in the year 1990 or later, and for each album,
retrieve the album name, release year, genre, and the name of the artist.

Ans.

1. Insert a new record into the `IndianAlbums` table:


INSERT INTO IndianAlbums (AlbumName, ReleaseYear, Genre, Sales,
Language)
VALUES ('Lagaan', 2001, 'Soundtrack', 5000000, 'Hindi');

2. Update the sales of the album with `AlbumID` 3:


UPDATE IndianAlbums
SET Sales = 1000000
WHERE AlbumID = 3;

3. Delete the record of the album named "Dil Se":


DELETE FROM IndianAlbums
WHERE AlbumName = 'Dil Se';
4. Alter the table structure to add a new column "Language":
ALTER TABLE IndianAlbums
ADD Language VARCHAR(50);

5. Select all albums released in the year 1990 or later:


SELECT I.AlbumName, I.ReleaseYear, I.Genre, A.ArtistName
FROM IndianAlbums I,Artist_Info A
WHERE I.ReleaseYear >= 1990 and I.ArtistID = A.ArtistID;
34 Rajat Parivahan Upkaram Pvt. Ltd. has established its presence in two cities: 5
Kaithal and Sirsa. The Kaithal city office has 4 blocks named K1, K2, K3 and
K4 and Sirsa is a franchise 400 kms away. The tables given below show the
distance between different blocks and the number of computers in each block.

Distance
(in m) K1 K2 K3 K4

K1 0 70 150 60

K2 70 0 130 50

K3 150 130 0 100

K4 60 50 100 0

Block No. of Workstations (Computers)

K1 50

K2 150

K3 30

K4 70

The company is planning to form a network by joining these blocks and two
offices. Answer the following questions to help them out:
1. Suggest the most appropriate block for placing the network server out of four
blocks.
2. To ensure efficient communication among the three cities, propose a
suitable network topology and provide a network diagram illustrating the
structure.
3. Please specify which city branch you choose as the LAN and why?.
4. Suggest the optimal placement of the following devices:
- Repeater
- Firewall
5. Company is planning to use VPN. Expand the term VPN and clarify its
significance within this network setup.

Ans.
1. K2 (Most no. of Workstations)
2. Star Topology (Draw the layout with K2 in the centre)

Kaithal Office

400 Kms

R epeater

Sirsa Branch

3. Kaithal, as all 4 blocks are in the same city and within few meters.
4.
- Repeater between K2 and K3 as the distance is >100 m to amplify the
signal
- Firewall should be placed at K2 as it forms the network perimeter
5. Virtual Private Network. It encrypts the communication thus making it
secure.
35 Month Wise sale of iphone 14 is given below: 5
data = { "Month": ["Sep22", "Oct22", "Nov22", "Dec22", "Jan23", "Feb23",
"Mar23", "Apr23"],
"Sales": [1000000, 1200000, 1500000, 2000000, 1800000, 1700000, 1600000,
1500000] }
Draw a line plot based on this data to know the trend of sales in two quarters (8
months). Use appropriate customisations.

Ans.
import pandas as pd
import matplotlib.pyplot as plt
data = {
"Month": ["Sep22", "Oct22", "Nov22", "Dec22", "Jan23", "Feb23", "Mar23",
"Apr23"],
"Sales": [1000000, 1200000, 1500000, 2000000, 1800000, 1700000,
1600000, 1500000]
}
df = pd.DataFrame(data)

# Create the line plot


plt.plot(df['Month'], df['Sales'], marker='o', linestyle='-')

# Customize the plot


plt.title('Monthwise Sales of iPhone 14 (Sep22 - Apr23)')
plt.xlabel('Month')
plt.ylabel('Sales')
plt.grid(True, linestyle='--', linewidth=0.5) #Optional
# Rotate the x-axis
axis labels for better readability
plt.xticks(rotation=45, ha="right") #Optional
#

plt.show()

OR
Write suitable Python code to create aBar Chart showcasing the medal
talley of top of countries in the asia cup 2023.

# medal count
medals = [88, 60, 58, 43, 35]

Ans.

import matplotlib.pyplot as plt


countries = ["China", "India", "Japan", "South Korea", "Iran"]
medals = [88, 60, 58, 43, 35]
plt.bar(countries, medals, color=['blue', 'green', 'red', 'purple', 'orange'])
plt.title("Top 5 Medal Winner Countries in Asia Cup Tournament 2023")
plt.xlabel("Countries")
plt.ylabel("Number of Medals")
plt.xticks(rotation=45, ha="right")
ha="rig #Optional
plt.grid(True, linestyle='--',', linewidth=0.5) #Optional
plt.show()
KENDRIYA VIDYALAYA SANGATHAN, JAIPUR REGION
FIRST PREBOARD EXAMINATION 2023-24
CLASSXII
INFORMATICS PRACTICES(065)
TIME:3 HOURS M.M.70

General Instructions:
1. This question paper contains five sections, Section A to E.
2. All questions are compulsory.
3. Section A have 18 questions carrying 01 mark each.
4. Section B has 07 Very Short Answer type questions carrying02 marks each.
5. Section C has 05 Short Answer type questions carrying 03 marks each.
6. Section D has03 Long Answer type questions carrying 05marks each.
7. Section E has02 questions carrying 04 marks each. One internal choice is given in Q 34
and 35 against part c only.
8. All programming questions are to be answered using Python Language only.
9. 3333333333

PARTA
1. It is a world-wide network which is a collection of many other networks 1
a) Internet
b) Website
c) Web Page
d) LAN
2. It is an act of copying another person’s data idea, words or work and pretended that they 1
are our own.
a) Copyright
b) Virus
c) Plagiarism
d) IPR
3. Choose the method(s) used for managing e-Waste. 1
a) Reducingb) Reusingc) Recycling d) All of these
4. Which type of values will not be considered by SQL while executing the following 1
statement?
SELECT COUNT(column name) FROM STOCK;
a) Null value
b) Text value
c) Numeric value
d) Date value
5. In a table SHOP, column “Margin” contains the data 1
set(2.00,2.00,NULL,4.00,NULL,3.00,3.00).What will be the output after the execution of the
query given below?
SELECT AVG(Margin) FROM SHOP;
a) 2.9 b) 2.8 c)2.00 d) None of these
6. ‘P’ in IPR stands for 1
a) Proprietary
b) Platform
c) Patent
d) Property
7. Which of the following is not a category of MySQL functions? 1
a) Text Functions
b) Mathematical Functions
c) Aggregate Functions
d) Arithmetic Functions
8. Select the output of the following SQL Command : - 1
SELECT ROUND(568.45,-1)
a) 570
b) 550
c) 568
d) 600
9. Which of the following function is similar to LCASE () function? 1
a) Lowercase()
b) Lower()
c) Lower_case()
d) All of the these
10 To display Third Element of a Series object S,you will write : 1
. a) S[:3]
b) S[2]
c) S[3]
d) S[:2]
11 Choose statement from the statements given below which is not correct in the context of a 1
. DataFrame?
a) size is Mutable
b) Can perform Arithmetic operators on rows and columns.
c) Homogeneous tabular data structure
d) Two dimensional
12 Which attribute is not used with the Dataframe? 1
. a) size
b) column
c) empty
d) type
13 A computer program designed to simulate conversation with human users especially is 1
. known as
a) e-mail
b) Chat group
c) Whatsapp
d) Chat bot
14 Suppose you have a DATETIME “2023-11-10 12:50:10” value. Which function extracts the 1
. date part of the given DATETIME value.
a) CURRENT()
b) NOW()
c) SYSDATE()
d) DATE()
15 What is the name of the IT law that India is having in the Indian Legislature? 1
. a) India’s Technology(IT) Act,2000
b) India’s Digital Information Technology(DIT),Act,2000
c) India’s Information Technology(IT),Act ,2000
d) The Technology Act,2008
16 Which of the following are automatically granted to creators and authors? 1
. a) Copyright
b) Patent
c) Trademark
d) Netiquette
Q17and18areASSERTIONANDREASONING basedquestions. Mark thecorrect choiceas
i. BothAand Raretrue andRisthecorrectexplanationforA
ii. BothAand Raretrueand Ris not the correctexplanation forA
iii. Ais Truebut Ris False
iv. Ais false butR is True
17 ASSERTION (A):E-waste can be toxic and harmful for nature 1
. REASONING(R):E-Waste that do not organically break down can, over time, can seep
directly into the environment
18 ASSERTION(A):drop() function removes data from a Dataframe temporarily. 1
. REASONING(R): Axis parameter is compulsory with drop() function.
PARTB
19 What do you understand by a website? Mention any two points of difference between 2
aWebsite and Webpage?
OR
“Switch is an intelligent Hub”. State Yes or No with reason.
20 Gopi Krishna is using a table Employee which has columns - 2
Code,Name,Salary,Deptcode. He wants to display maximum salary department wise but
he did not get the desired result. Rewrite the query given below with necessary change to
help him get the desired result.
SELECT Deptcode,MAX(Salary) FROM Employee;
21 In SQL, differentiate HAVING and WHERE clause? 2
.
22 Consider the given data and write a python program to create a series named Subject 2
. using a dictionary.
English 75
Hindi 78
Math 82
Science 88

23 Explain any two physical problems of using technology excessively. 2


. OR
What is meant by digital footprint? Give example of one active and one passive digital
footprint?

24 What will be the output of the following code: 2


.
import pandas as pd
numbers=pd.Series([9,8,7,6,5],index=range(0,10,2))
print(numbers[1:3]

25 Answer the following questions based on the code given below : - 2


. …………………….... # Statement 1
Ld=[{'a',10,'b':20},{'a':5,'b':10,'c':20}]
df=pd.DataFrame(Ld)
print(df)
i) Write the statement 1 in the above code.
ii) How many columns will be there in the dataframe.
SECTION C
26 Write a python code to create a DataFrame with appropriate column headings from the list 3
. given below:
[[201,’Gurmeet’,95],[202,’Praveen’,89],[203,’Suman’,97],[204.’Yogesh’,91]]

27 Consider the given DataFrame ‘Fees’: 3


.
Cname Fee
0 XII 3500
1 XI 3000
2 X 2700
3 VII 1800

Write suitable Python statements for the following:


i. Add a column called ‘Section’ with the data: [‘A’,’B’,’C’,’D’]
ii. Add a new Class Name named ‘IX' having price 1800.
iii. Remove the column ‘Section’.
28 Write SQL commands for the statements (i) to (iii) which are based on the given table 3
. WORKER.
PI GE PINCO SALA
SNAME FNAME CITY
D N DE RY
SHARM
1 GEET F JAMMU 182141 50000
A
SURINDE
2 SINGH M KANPUR 193222 75000
R
3 JCOB PETER M MUMBAI 185155 45000
4 ALVIS THOMAS M GURUGRAM 380025 50000
MOHA
5 GAURAV M KOLKATA 390026 33000
N
6 AZMI SIMI F NEW DELHI 110021 40000
MANPRE
7 KAUR F JAMMU 182141 42000
ET

i) SELECT SUM(SALARY) FROM PERSON WHERE GEN=’F’;


ii) SELECT GEN,COUNT(*) FROM PERSON GROUP BY GEN;
iii) SELECT MOD(SALARY,4000) FROM PERSON WHERE CITY=‘JAMMU’;

29 NISHA has recently changed his school so she is not aware of the people, but someone is 3
posting negative demeaning comments on his social media profile. She is also getting
repeated mails from unknown people. Every time she goes online, she finds someone
chasing him online.
i. Nisha is a victim of ___________.
ii. The action that Nisha should take to handle it.
iii. .......................... is a set of moral principles that governs the behavior of a group or
individual and regulates the use of computers.
OR
What do you understand by plagiarism? Why is it a punishable offence? Mention any two
ways to avoid plagiarism.
30 Consider a table “AGENT”” with the following data: 3
Table : AGENT
SNO ANAME SALAR BONU DOJ
Y S
A01 Beena Mehta 30000 45.23 29-10-2019
A02 K.L. Sahay 50000 25.34 13-03-2018
B03 Nisha Thakkar 30000 35.00 18-03-2017
B04 Leela Yadav 80000 NULL 31-12-2018
C05 Gautam Gola 20000 NULL 23-01-1989
Write SQL queries to
perform the following operations.
(i) Display Agent name and bonus after rounding off to zero decimal places.
(ii) Display the month name of the date of join (DOJ) of all the agents who have no bonus.
bonus
(iii) Display the
e minimum salary of all the agents
agents.
OR
What is the purpose of GROUP BY clause in MySQL? How is it different from ORDER BY
clause?
SECTION D
31 Write suitable SQL query for the following: 5
. i. Display 7 characters extracted from 7 th characterharacter onwards from the string
‘INDIASHINING’.
ii. Display the position of occurrence of string ‘COME’ in the string‘WELCOME WORLD’.
iii. Round off the value 78.779 to 2nd decimal place.
iv. Display the remainder of 1 149 divided by 6.
v. Remove all the expected leading and trailing spaces from a column USERID of the table
‘USERS’.
OR
Explain the following SQL functions using suitable examples.
i. LENGTH()
ii.RTRIM()
iii. NOW()
iv. DAYNAME()
v. POWER()
v. POWER(
32 VIKRAMA UNIVERSITY, Allahabad is setting up the network between its different wings. 5
. There are four wings named as Science(S), Journalism(J), Arts(A) and Home Science(H).

Distance between various wings

a. Suggest a suitable layout for networking the computers in each wing.


b. Name the wing where server needs to be installed.
c. Suggest the placement of Hub/Switch in the network.
d. Suggest type of wired media to provide internet accessibility to all wings.
e. University is planning to get its website designed which will allow students to see their
results after registering themselves on its server. Out of the static or dynamic, which type of
website will you suggest?

33 Mr. Gupta is working in a game development industry and he was comparing the given chart 5
on the basis of the rating of the
various games available on
the play store.

Write the python code for the above graph and Also give suitable python statement to save
this chart.
OR
Write a python program to plot a line chart based on the given data to depict the pass
percentage of students in CBSE exams for the years 2018 to 2022 as shown below.

Year=[2018,2019,2020,2021,2022]
Pass_Percentage=[85,83,90,82,92]

SECTION E
34 Naveen, a database administrator has designed a database for a Computer Stock. Help him 1+
by writing answers of the following questions based on the given table: 1+
2
TABLE: INVENTORY

Pid Pname Categor Qty Price


y
1 Keyboard IQ 15 450
2 Mouse IQ 10 350
3 Wi-fi router NW 5 2600
4 Switch NW 3 3000
5 Printer O 4 17000

i. Write a query to display product name in upper case.


ii. To display the records in descending order of the price.
iii. To display category and category wise highest price of product.
OR (Option for part iii only)
To display category and category wise total quantities of product.

35 Assume a DataFrame df has following data of passengers for the year 2010 to 2012 for
. January, March and December. Find output of the following python statements given 1+
below: - 1+
2
Year Mont Passengers
h
0 2010 Jan 25
1 2010 Mar 50
2 2012 Jan 35
3 2010 Dec 55
4 2012 Dec 65

i. df.columns
ii. df.shape
iii. df[df.Passengers>50]
OR (Option for part iii only)
df.tail(3)
KENDRIYA VIDYALAYA SANGATHAN, JAIPUR REGION
FIRST PREBOARD EXAMINATION 2023-24
CLASSXII
INFORMATICS PRACTICES(065)
TIME:3 HOURS M.M.70

General Instructions:
1. This question paper contains five sections, Section A to E.
2. All questions are compulsory.
3. Section A have 18 questions carrying 01 mark each.
4. Section B has 07 Very Short Answer type questions carrying02 marks each.
5. Section C has 05 Short Answer type questions carrying 03 marks each.
6. Section D has03 Long Answer type questions carrying 05marks each.
7. Section E has02 questions carrying 04 marks each. One internal choice is given in Q 35
against part c only.
8. All programming questions are to be answered using Python Language only.
9.

PARTA
1. It is a world-wide network which is a collection of many other networks 1
a) Internet
b) Website
c) Web Page
d) LAN
An a) Internet
s
2. It is an act of copying another person’s data idea, words or work and pretended that 1
they are our own.
a) Copyright
b) Virus
c) Plagiarism
d) IPR
An b) Plagiarism
s
3. Choose the method(s) used for managing e-Waste. 1
a) Reducingb) Reusingc) Recycling d) All of these
An d) All of these
s
4. Which type of values will not be considered by SQL while executing the following 1
statement?
SELECT COUNT(column name) FROM STOCK;
a) Null value
b) Text value
c) Numeric value
d) Date value
An a) Null value
s
5. In a table SHOP, column “Margin” contains the data 1
set(2.00,2.00,NULL,4.00,NULL,3.00,3.00).What will be the output after the execution of
the query given below?
SELECT AVG(Margin) FROM SHOP;
a) 2.9 b) 2.8 c)2.00 d) None of these

An b) 2.8
s
6. ‘P’ in IPR stands for 1
a) Proprietary
b) Platform
c) Patent
d) Property
An d) Property
s
7. Which of the following is not a category of MySQL functions? 1
a) Text Functions
b) Mathematical Functions
c) Aggregate Functions
d) Arithmetic Functions
An d) Arithmetic Functions
s
8. Select the output of the following SQL Command : - 1
SELECT ROUND(568.45,-1)
a) 570
b) 550
c) 568
d) 600
An a) 570
s
9. Which of the following function is similar to LCASE () function? 1
a) Lowercase()
b) Lower()
c) Lower_case()
d) All of the these
An b) lower()
s
10. To display Third Element of a Series object S,you will write : 1
a) S[:3]
b) S[2]
c) S[3]
d) S[:2]
An b) S[2]
s
11. Choose statement from the statements given below which is not correct in the context of 1
a DataFrame?
a) size is Mutable
b) Can perform Arithmetic operators on rows and columns.
c) Homogeneous tabular data structure
d) Two dimensional
An c) Homogeneous tabular data structure
s
12. Which attribute is not used with the Dataframe? 1
a) size
b) column
c) empty
d) ndim
An b) column
s
13. A computer program designed to simulate conversation with human users especially is 1
known as
a) e-mail
b) Chat group
c) Whatsapp
d) Chat bot
An d) Chat bot
s
14. Suppose you have a DATETIME “2023-11-10 12:50:10” value. Which function extracts 1
the date part of the given DATETIME value.
a) CURRENT()
b) NOW()
c) SYSDATE()
d) DATE()
An d) DATE()
s
15. What is the name of the IT law that India is having in the Indian Legislature? 1
a) India’s Technology(IT) Act,2000
b) India’s Digital Information Technology(DIT),Act,2000
c) India’s Information Technology(IT),Act ,2000
d) The Technology Act,2008
An c) India’s Information Technology(IT),Act ,2000
s
16. Which of the following are automatically granted to creators and authors? 1
a) Copyright
b) Patent
c) Trademark
d) Netiquette
An a) Copyright
s
Q17and18areASSERTIONANDREASONING basedquestions. Mark thecorrect
choiceas
i. BothAand Raretrue andRisthecorrectexplanationforA
ii. BothAand Raretrueand Ris not the correctexplanation forA
iii. Ais Truebut Ris False
iv. Ais false butR is True
17. ASSERTION (A):E-waste can be toxic and harmful for nature 1
REASONING(R):E-Waste that do not organically break down can, over time, can seep
directly into the environment
An i) Both A and R are true and R is the correct explanation for A
s
18. ASSERTION(A):drop() function removes data from a Dataframe temporarily. 1
REASONING(R): Axis parameter is not compulsory with drop() function.
An iv) A is false but R is True
s
PARTB
19 What do you understand by a website? Mention any two points of difference between 2
aWebsite and Webpage?
OR
“Switch is an intelligent Hub”. State Yes or No with reason.
An Website
s A website is a collection of webpages and related content that is identified by a
common domain name and published on a web server.
- Website is a collection of webpage whereas web page is an individual page and
part of a website
- Website has domain name whereas webpage URL to access it
- Website is larger than a webpage
- Website takes longer to develop as compared to web page
1 mark for definition and 1 mark for any two correct point of difference
OR
Yes, switch is an intelligent hub because it sends received or incoming data/packets to
its recipient node only and provide point-to–point communication using MAC address.
1 mark for Yes and 1 mark for correct reason

20 Gopi Krishna is using a table Employee which has columns - 2


Code,Name,Salary,Deptcode. He wants to display maximum salary department wise
but he did not get the desired result. Rewrite the query given below with necessary
change to help him get the desired result.
SELECT Deptcode,MAX(Salary) FROM Employee;
An SELECT Deptcode, MAX(Salary) FROM Employee Group by Deptcode
s 2 marks for correct answer (Partial mark may be awarded)
21. In SQL, differentiate HAVING and WHERE clause? 2
An HAVING Clause
s - It is used only with GROUP BY clause to specify conditions on whole group or
aggregate function.
WHERE Clause
- It is used to specify condition on individual attribute(s) to filter the tuples/records, it
has no relation with GROUP BY clause
1 mark each for two correct point of differences

22. Consider the given data and write a python program to create a series named Subject 2
using a dictionary.
English 75
Hindi 78
Math 82
Science 88
An import pandas as pd ½ mark
s D={“English”:75,”Hindi”:78,”Math”:82,”Science”:88} ½ mark
Subject=pd.Series(D) ½ mark
print(Subject) ½ mark
23. Explain any two physical problems of using technology excessively. 2
OR
What is meant by digital footprint? Give example of one active and one passive digital
footprint?

An i. Sleep problem
s ii. Eyestrain
iii. Neck pain
iv. Headaches
v. Muscular pain
2 marks for any two correct point of differences

OR
Digital foorprints
A digital footprint is the trail of data created as a result of you online activity.
[1 mark]
Active Digital footprint – Logging in, posting comments, liking someone’s image etc [
½ mark]
Passive footprint – Your IP address, Browser history, clicking on a link or surfing on net
[ ½ mark]
24. What will be the output of the following code: 2

import pandas as pd
numbers=pd.Series([9,8,7,6,5],index=range(0,10,2))
print(numbers[1:3]

An 2 8
s 4 7
½ mark for each correct value of output ( ½ x 4 = 2 marks)
25. Answer the following questions based on the code given below : - 2
…………………….... # Statement 1
Ld=[{'a',10,'b':20},{'a':5,'b':10,'c':20}]
df=pd.DataFrame(Ld)
print(df)
i) Write the statement 1 in the above code.
ii) How many columns will be there in the dataframe.

An i) import pandas as pd [1 mark]


s ii) 3 columns [1 mark]
SECTION C
26. Write a python code to create a DataFrame with appropriate column headings from 3
the list given below:
[[201,’Gurmeet’,95],[202,’Praveen’,89],[203,’Suman’,97],[204.’Yogesh’,91]]
An import pandas as pd
s [½ mark]
data=[[201,'Gurmeet',95],[202,'Praveen',89],[203,'Suman',97],[204,'Yogesh',91]]
[ ½ mark]
df=pd.DataFrame(data,index=["S1","S2","S3","S4"],columns=["Rollno","Name","Marks"
]) [ 1 ½ marks]
print(df)
[ ½ mark]
27. Consider the given DataFrame ‘Fees’: 3

Cname Fee
0 XII 3500
1 XI 3000
2 X 2700
3 VII 1800

Write suitable Python statements for the following:


i. Add a column called ‘Section’ with the data: [‘A’,’B’,’C’,’D’]
ii. Add a new Class Name named ‘IX' having price 1800.
iii. Remove the column ‘Section’.
An i. Fees[“Section”]= [‘A’,’B’,’C’,’D’] [1 mark]
s ii. Fees.loc[4]=[“IX”1800] [1 mark]
iii. Fees.pop(“Section”) or Fees=Fees.drop(“Section”,axis=1) [1 mark]
28. Write SQL commands for the statements (i) to (iii) which are based on the given table 3
WORKER.
PID SNAME FNAME GEN CITY PINCODE SALARY
1 SHARMA GEET F JAMMU 182141 50000
2 SINGH SURINDER M KANPUR 193222 75000
3 JCOB PETER M MUMBAI 185155 45000
4 ALVIS THOMAS M GURUGRAM 380025 50000
5 MOHAN GAURAV M KOLKATA 390026 33000
6 AZMI SIMI F NEW DELHI 110021 40000
7 KAUR MANPREET F JAMMU 182141 42000

i) SELECT SUM(SALARY) FROM PERSON WHERE GEN=’F’;


ii) SELECT GEN,COUNT(*) FROM PERSON GROUP BY GEN;
iii) SELECT MOD(SALARY,4000) FROM PERSON WHERE CITY=‘JAMMU’;

An i) [1 mark]
s Sum(Salary)
132000
ii) [1 mark]
GEN COUNT(*)
F 3
M 4
iii) [1 mark]
MOD(Salary,4000)
2000
2000
29 NISHA has recently changed his school so she is not aware of the people, but 3
someone is posting negative demeaning comments on his social media profile. She is
also getting repeated mails from unknown people. Every time she goes online, she
finds someone chasing him online.
i. Nisha is a victim of ___________.
ii. The action that Nisha should take to handle it.
iii. .......................... is a set of moral principles that governs the behavior of a group or
individual and regulates the use of computers.
OR
What do you understand by plagiarism? Why is it a punishable offence? Mention any
two ways to avoid plagiarism.

An i) Cyber bullying/Cyber stalking [1 mark]


s ii) She should tell to her parents/guardians about it and lodge an FIR to nearest
police station under IT Act of India, 2000 [1 mark]
iii) Netiquettes [1 mark]

OR
Plagiarism
It means using someone else’s work without giving them proper credit or showing it your
own creations.
It is a punishable offence because it may result in a financial loss to the creator or an
intellectual property and also violating IPR is also a punishable offence.
Ways to avoid plagiarism: -
1. Give credit to the creator
2. Mention the source of the information
3. Create your own content
4. Do not copy paste
1 mark for definition 1 mark for two correct points ( ½ each)
30 Consider a table “AGENT” with the following data: 3
Table : AGENT
SNO ANAME SALARY BONUS DOJ
A01 Beena Mehta 30000 45.23 29-10-2019
A02 K.L. Sahay 50000 25.34 13-03-2018
B03 Nisha Thakkar 30000 35.00 18-03-2017
B04 Leela Yadav 80000 NULL 31-12-2018
C05 Gautam Gola 20000 NULL 23-01-1989
Write SQL queries to perform the following operations.
(i) Display Agent name and bonus after rounding off to zero decimal places.
(ii) Display the month name of the date of join (DOJ) of all the agents who have no
bonus.
(iii) Display the minimum salary of all the agents.
OR
What is the purpose of GROUP BY clause in MySQL? How is it different from ORDER
BY clause?
Ans i) SELECT ANAME,ROUND(BONUS,2) FROM AGENT[1 mark]
ii) SELECT MONTHNAME(DOJ) FROM AGENT WHERE BONUS IS NULL[1
mark]
iii) SELECT MIN(SALARY) FROM AGENT[1 mark]
OR
Group By
Is used to create group of rows having similar values in the specified column.[1 mark]
Example : - SELECT DEPT, COUNT(*) FROM EMPLOYEE GROUP BY DEPT
ORDER BY is used to arrange tuples/rows in ascending or descending order according
to the values in a given column.
Example : - SELECT * FROM EMPLOYEE ORDER BY DEPT[1 mark]
SECTION D
31. Write suitable SQL query for the following: 5
i. Display 7 characters extracted from 7th character onwards from the string
‘INDIASHINING’.
ii. Display the position of occurrence of string ‘COME’ in the string‘WELCOME
WORLD’.
iii. Round off the value 78.779 to 2nd decimal place.
iv. Display the remainder of 149 divided by 6.
v. Remove all the expected leading and trailing spaces from a column USERID of the
table ‘USERS’.
OR
Explain the following SQL functions using suitable examples.
i. LENGTH()
ii.RTRIM()
iii. NOW()
iv. DAYNAME()
v. POWER()
v. POWER(
An i) SELECT SUBSTR(‘INDIASHINING’,7,7)/ SELECT
s SUBSTRING(‘INDIASHINING’,7,7) /
SELECT MID(‘INDIASHINING’,7,7)
[1 mark]
ii) SELECT INSTR(‘WELCOME WORLD’,’COME’)
[1 mark]
iii) SELECT ROUND(78.779,2)
[1 mark]
iv) SELECT MOD(149,6)
[1 mark]
v) SELECT TRIM(USERID) FROM USERS
[1 mark]
OR
i) LENGTH() Returns
Returns length/number of characters of a given string.
ii) RTRIM()  Returns a string by removing all trailing spaces from a given string
iii) NOW()  Return current date and time of the system
iv) DAYNAME() Returns day name of the day of given date
v) POWER()  Return x raise to the power of y
1 mark each for correct definition
32. VIKRAMA UNIVERSITY, Allahabad is setting up the network between its different 5
wings. There are four wings named as Science(S), Journalism(J), Arts(A) and Home
Science(H).

Distance between various wings

a. Suggest a suitable layout for networking the computers in each wing.


b. Name the wing where server needs to be installed.
c. Suggest the placement of Hub/Switch in the network.
d. Suggest type of wired media to provide internet accessibility to all wings.
e. University is planning to get its website designed which will allow students to see their
results after registering themselves on its server. Out of the static or dynamic, which
w
type of website will you suggest?

An a. [1 mark star or bus topology ]


J
s A

S
H
b. Wing A [1mark]
c. In all the wings [1 mark]
d. Ethernet cable [1 mark]
e. Dynamic website [1 mark]

33 Mr. Gupta is working in a 5


game development industry
and he was comparing the
given chart on the basis of
the rating of the various
games available on the
play store.

Write the python code for the above graph and Also give suitable python statement to
save this chart.
OR
Write a python program to plot a line chart based on the given data to depict the pass
percentage of students in CBSE exams for the years 2018 to 2022 as shown below.

Year=[2018,2019,2020,2021,2022]
Pass_Percentage=[85,83,90,82,92]

An import matplotlib.pyplot as plt [ ½ mark]


s rating=[4.2,4.8,5.0,3.6,4.0]
games=["Subway surfer”,"Temple Run","Candy Crush","Bottle shot","Runner Best"]
plt.bar(rating,games) [1 mark]
plt.xticks([0,1,2,3,4],games)
plt.title("Rating of games") [½ mark]
plt.xlabel("Games") [½ mark]
plt.ylabel("Rating") [½ mark]
plt.show() [1 mark]
plt.savefig(‘games.jpg’) [1 mark]
OR
import matplotlib.pyplot as plt [ ½ mark]
Year=[2018,2019,2020,2021,2022]
Pass_Percentage=[85,83,90,82,92]
plt.plot(Year,Pass)[ 2 mark]
plt.title("Pass percentages in CBSE ")[ ½ mark]
plt.xlabel("Year")[ ½ mark]
plt.ylabel("Percentage")[ ½ mark]
plt.show()[ 1 mark]

SECTION E
34 Naveen, a database administrator has designed a database for a Computer Stock. Help 1+1+
him by writing answers of the following questions based on the given table: 2

TABLE: INVENTORY

Pid Pname Category Qty Price


1 Keyboard IQ 15 450
2 Mouse IQ 10 350
3 Wi-fi router NW 5 2600
4 Switch NW 3 3000
5 Printer O 4 17000

i. Write a query to display product name in upper case.


ii. To display the records in descending order of the price.
iii. To display category and category wise highest price of product.
OR (Option for part iii only)
To display category and category wise total quantities of product.

An i. SELECT UPPER(Pname) FROM INVENTORY [1 mark]


s ii. SELECT * FROM INVENTORY ORDER BY PRICE DESC [1
mark]
iii. SELECT CATEGORY, MAX(PRICE) FROM INVENTORY GROUP BY
CATEGORY; OR
SELECT CATEGORY, SUM(Qty) FROM INVENTORY GROUP BY
CATEGORY; [2 marks]
35. Assume a DataFrame df has following data of passengers for the year 2010 to 2012 for
January, March and December. Find output of the following python statements given 1+1+
below: - 2

Year Month Passengers


0 2010 Jan 25
1 2010 Mar 50
2 2012 Jan 35
3 2010 Dec 55
4 2012 Dec 65

i. df.columns
ii. df.shape
iii. df[df.Passengers>50]
OR (Option for part iii only)
df.tail(3)

An i) [“Year”,”Month”,”Passengers”]
s ii) (5,3)
iii)
Year Month Passengers
3 2010 Dec 55
4 2012 Dec 65
OR

Year Month Passengers


2 2012 Jan 35
3 2010 Dec 55
4 2012 Dec 65
KENDRIYA VIDYALAYA SANGATHAN, HYDERABAD REGION 2023-24
INFORMATICS PRACTICES(065) CLASS XII
PREBOARD-1 (MARKING SCHEME)
MM:70
TIME:3Hrs.

SECTION-A
1 B .25 (1 mark for correct answer) 1
2 C SUM 1
3 B INSTR (1 mark for each correct answer) 1
4 A Uniform resource Locator (1 mark for each correct answer) 1
5 B read_csv (1 mark for each correct answer) 1
6 A Phishing (1 mark for each correct answer) 1
7 D Kitchen waste (1 mark for each correct answer) 1
8 c) Browser settings and web server (1 mark for each correct answer) 1
9 D S.data (1 mark for each correct answer) 1
10 D matplotlib 1
11 C Python (1 mark for each correct answer) 1
12 D SELECT * FROM EMPLOYEE ORDER BY DOJ ; 1
13 b) Server 1
14 D Both a and b (1 mark for each correct answer) 1
15 C Digital foot print 1
16 D 6700.00 (1 mark for each correct answer) 1
17 ii.Both A and R are true and R is not the correct explanation for A 1
18 i) Both A and R are true and R is the correct explanation for A 1
SECTION-B
19 ▪ Switch works similarly like hub but in a more efficient manner. It creates 2
connections dynamically and provides information only to the requesting
port.
▪ Router is smartest and most complicated out of the three. It comes in all
shapes and sizes. Routers are located at gateway and forwards packets in a
network.
1 mark for each Switch and Router
OR
Any four differences ½ Mark each
20 import pandas as pd 2
d={“Productname”:[“monitor”,”Keyboard”],”Price”:[4500,500]}
df=pd.DataFrame(d)
print(df)
½ mark for each correction

21 i) 2 2
ii) IS W

22 import pandas as pd½ mark 2


S=pd.series({“ENG”:23,”ECO”:24,”IP”:24,”ACCT”:26,”BST”:21})
1mark for any other correct statement
print(S) ½ mark
a) product.drop(“B”) 1mark for any other correct statement
b) product[“Qty”]=[3,4] 1mark

23 IPR are the creations of mind. Ownership on the inventions, literary and 2
artistic expressions, designs and symbols, names and logos created by a
person possess rights on his work.1mark
Trademark, Patents, copy rights 1mark
24 i) print(Prices[Price<30]) ii) Price=Price+3 2
25 In database management an aggregate function is a function where the 2
values of multiple rows are grouped together as input on certain criteria
to form a single value of more significant meaning.

1m for proper explanation

Any two from given below . 1m for each aggregate function


1) Count()
2) Sum()
3) Avg()
4) Min()
5) Max()
SECTION-C
26 i) SELECT min(Hundreds),max(Hundreds) From PLAYERS; 3
ii) SELECT player FROM Players ORDER BY Avgrunsdesc
iii) SELECT LEFT(player,5) FROM PLAYERS;
OR
i) 2 ii) hli iii) Virat Kohli 57.6
kar M S Dhoni 50.2
27 Science Commerce Humanities 3
11A 30 20 12
11B 34 21 14
12A 40 19 16
12B 25 18 19

Science 34
Commerce 21
Humanities 14

30

11A 11B 12A 12B


Science 30 34 40 25
Commerce 20 21 19 18
Humanities 12 14 16 19
28 SELECT s.name AS "Salesman", c.cust_name, c.city FROM salesman s, 3
customer c WHERE s.city=c.city;
OR 1
SELECT salesman.name AS "Salesman", customer.cust_name,
customer.city
FROM salesman,customer WHERE salesman.city=customer.city;

b. write a SQL query to display ord_no, purch_amt, cust_name, city of


those orders where order amount exists between 500 and 2000.
Ans:
SELECT o.ord_no,o.purch_amt, c.cust_name,c.city FROM orders
o,customer c WHERE o.customer_id=c.customer_id AND o.purch_amt
BETWEEN 500 AND 2000; 1

c. Write a SQL query to display Customer Name, city, Salesman,


commission the all salesperson(s) and their respective the customer(s).
Ans:
SELECT c.cust_name AS "Customer Name", c.city, s.name AS "Salesman",
s.commission FROM customer c, salesman s WHERE
c.salesman_id=s.salesman_id; 1
29 i) Refers to the trail (evidences) of data you leave when using the 3
internet. It includes websites you visit, emails you send, and
information you submit online. 1mark
ii) Virus attack. Preventions keep backup , Install anti virus
update it at frequent intervals 1+1 marks
OR
i) 1 mark for defining netiquette and 1 mark each any two correct
netiquttes.
30 import pandas as pd1 mark correct case sensitive 3
D= _____ any valid statement using list of lists /dictionary of lists or
series 1 mark
df=pd.DataFrame(D) ½ mark
print(df) ½ mark

SECTION-D

31 Context Command 4
i) Add a new record to the table INSERT
ii) Add new column to the table ALTER TABLE
ADD
iii) Changing the value in a UPDATE -SET
particular record
iv) Removing the table from DROP TABLE
database completely

32 i) M.loc[3]={“Event”:Squash”,”Gold”:2,”Silver”: 1, “Bronze”: 2} 1mark 4


ii) M[[“Event”,”Gold”]] 1 mark
iii)M[total” ]=M[“Gold”]+M[“Silver”]+M[“Bronze”] 2 marks
or
M.to_csv(“E:\data.csv”)
2 marks
SECTION-E
33 i) SELECT * from ORDER where Month(OrderDate)=10; 5
ii) SELECT * from ORDER Order by Price Acs;
iii) SELECT DAY(Orderdate) from order where Item_desc=”shirt”;
iv) UPDATE Order set price= 210 where Item_desc=”Story Book”;
v) DELETE from ORDER where orderid=165 ;
OR
i) 154
ii) INSTR(Item_desc,”st”)
1
0
0
0
4
iii) 12
iv) OrderidMOD(price,Qty)
127 2
209 0
v) Item_desc,MONTH(OrderDate)
Shirt 09
Electronic gadget 08

34 i) Correct layout 1mark 5


ii) Suggest the placement of following devices with justification
a) SWITCH – All sections b) MODEM- admin
iii) Firewall iv)Wifi device v) Radiowave
35 import matplotlib.pyplot as plt1 mark for import library 5
import numpy as np
X=np.array([1,2,3,4,5])
I=[5,8,2,3,6]1mark for data in two lists
A=[4,6,5,3,2]
plt.bar(X,I,color="Blue", width=0.3,label="INDIA")1mark for correct
statement
plt.bar(X+0.3,A,color="red", width=0.3, label="AUSTRALIA")
plt.xlabel("OVERS")1mark for labels
plt.ylabel("RUNS")
plt.title("SCORES IN 5 OVERS")
plt.legend()
plt.show() I mark for show()
OR
import matplotlib.pyplot as plt # 1 mark for import library
import numpy as np
X=np.array([1,2,3,4,5])
I=[5,8,2,3,6] #1mark for data in two lists
A=[4,6,5,3,2]
plt.plot(X,I,color="Blue", linestyle='dotted',label="INDIA") # 1mark for
correct statement
plt.plot(X,A,color="red", linestyle='dashed', label="AUSTRALIA")
plt.xlabel("OVERS") #1mark for labels
plt.ylabel("RUNS")
plt.title("SCORES IN 5 OVERS")
plt.legend()
plt.show() 1 mark for show()

You might also like