XIIInfo Pract S E 427
XIIInfo Pract S E 427
XIIInfo Pract S E 427
PREBOARD1:2022-23
CLASS XII
Maximum Marks: 70 Time Allowed: 3 hours
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 03 Long Answer type questions carrying 05 marks each.
7. Section E has 02 questions carrying 04 marks each. One internal choice is given in Q35 against part c only.
8. All programming questions are to be answered using Python Language only
Section A
1. If DataFrame is created using a 2D dictionary , then the indexes/row labels are formed from
a) Dictionary’s values b) inner dictionary keys c) outer dictionary keys d) none of these
2. Which of the following statement is wrong in the context of DataFrame?
a) Two-dimensional size is mutable b) can perform arithmetic operations on rows and
columns
c) Homogenous Tabular data structure d) Create DataFrame from numpy ndarray
3. Which method is used to delete rows from DataFrame?
a) .drop() b) .del() c) .remove() d) .delete()
ASSERTION AND REASONING based questions. Mark the correct choice as
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.
4. Assertion (A):- DataFrame has both a row and column index.
Reasoning (R): - A DataFrame is a two-dimensional labelled data structure like a table of MySQL.
5. Assertion (A): An Internet troll is a person who deliberately sows discord on the Internet by
starting quarrels or upsetting people.
Reason (R): We can download and use any material available on the Internet.
6. The following is automatically granted to the creator or owner of any invention:
a) Patent b) Copyright c) Trademark d) License
7. ______ is defined as the crime in which computer is the medium of crime.
A) Computer Crime b) Cybercrime c) Internet Crime d) Digital Crime
8. Which of the following is not a cybercrime?
a) Phishing b) Ransom ware c) Hacking d) Tracking
9. Intellectual property rights protect the use of information and ideas that are of:
a) Ethical value b) Moral value c) Social value d) Commercial value
10. Unsolicited commercial email is known as _____.
a) Spam b) Malware c) Virus d) Spyware
11. In which topology are all the nodes connected through a single coaxial cable?
a) Star b) tree c) bus d) mesh
12. Which network device connects dissimilar networks?
a) Router b) Gateway c) Bridge d) Repeater
13. Which of these is not a communication channel?
a) Satellite ii) Microwave iii) Radio wave d) Wifi
14. Which clause is used in query to place the condition on groups in MySQL ?
a) where b) having c) group by d) both a and b
15. Which of the following function is not an aggregate function?
a) Round() b) Sum c) Count() d) Avg()
16. If column “Fees” contains the data set (5000,8000,7500,5000,8000), what will be the output
after the execution of the given query? SELECT SUM (DISTINCT Fees) FROM student;
a) 20500 b) 10000 c) 20000 d) 33500
17. Which SQL statement do we use to find out the total number of records present in the table ORDERS?
a) SELECT * FROM ORDERS; b) SELECT COUNT (*) FROM ORDERS;
c) SELECT FIND (*) FROM ORDERS; d) SELECT SUM () FROM ORDERS;
18. __________is the trail of data we leave behind when we visit any website (or use any online application
or portal) to fill-in data or perform any transaction.
a) Offline phishing b) Offline footprint c) Digital footprint d) Digital phishing
Section B
19. Explain the terms web page and home page .
Or
Explain the difference between static and dynamic web page.
20. What is the purpose of group by clause in SQL. Explain with the help of example.
21. Write a program to create a series object using a dictionary that stores the number of students in
each house of class 12C of your school.
Note: Assume four house names are Ganga, Yamuna, Thames, Niagra having 18, 2, 20, 18 students
respectively and pandas library has been imported as pd.
22. Discuss measures to recycle your e-waste safely.
Or
Describe some common forms of student plagiarism.
23. What is the difference between single row and multiple row function. Explain with the help of example.
24. What will be the output of the following code:
>>>import pandas as pd
>>>B=pd.Series(data=[35,85,55,40])
>>>print(B>45)
25. Carefully observe the following code:
import pandas as pd
Year1={'Q1':5000,'Q2':8000,'Q3':12000,'Q4': 18000}
Year2={'A' :13000,'B':14000,'C':12000}
totSales={1:Year1,2:Year2}
df=pd.DataFrame(totSales)
print(df)
Answer the following:
i. List the index of the DataFrame df
ii. List the column names of DataFrame df
Section C
26. Write outputs for SQL queries (i) to (iii) which are based on the given table PURCHASE:
CNO CNAME CITY QUANTITY DOP
C01 RAM DELHI 150 2022-02-04
C02 HARNOOR DALHOUSE 10 2021-06-07
C03 YASHWARDHAN CHNADIGARH 110 2022-11-25
C04 ASHUTOSH CHANDIGARH 50 2021-10-16
C05 KANIKA HYDERABAD 25 2020-01-01
i. SELECT LEFT(CNAME,2) FROM PURCHASE WHERE QUANTITY<100;
ii. SELECT CNAME FROM PURCHASE WHERE MONTH(DOP)=11;
iii. SELECT MOD (QUANTITY, DAY(DOP)) FROM PURCHASE WHERE CITY= ‘DALHOUSE’;
27. Write a Python code to create a DataFrame with appropriate column headings from the list given
below: [[101,'KHANAK',98],[102,'Rajinder',95],[103,'Samar' ,96],[104,'Yuvraj',88]]
28. Consider the given DataFrame ‘Stock’:
Table: EXAM
Adno SName Percentage Clsection Stream
R001 Sushant 90.2 12A Science
R002 Vaidyanath 80.5 12B Humanities
R003 Meera 68.9 12B Science
R004 Niara 96.0 12C Commerce
R005 Sanjhi 88.9 12D Commerce
i) . Display stream wise highest percentage.
ii. Display section wise lowest percentage.
iii. Display all the details of the students whose name starts with S.
or
Discuss the significance of wild cards in pattern matching with the help of example.
Section D
31. Write suitable SQL query for the following:
i. Display 5 characters extracted from 5th left character onwards from the string ‘INDIA SHINING’.
ii. Display the position of occurrence of string ‘CREDIB’ in the string ‘INCREDIBLE INDIA’.
iii. Round off the value 343.985 to one decimal place.
iv. Display the remainder of 800 divided by 13.
v. Remove all the expected leading and trailing spaces from a column SName of the table ‘EXAM’ (in
section C).
or
Explain the following SQL functions using suitable examples.
i. LCASE() ii. LTRIM() iii. SUBSTR() iv. MONTHNAME()
v. MOD()
32.
The Virtual Connects organization has set up its new centre at Noida for its office and web-
based activities. It has 4 blocks of buildings as shown in the diagram below:
(i) Suggest the most suitable place (the Block) to install the server of this organization with
asuitable reason.
(ii) Which device will you suggest to be placed/installed in each of these blocks to efficiently
connect all the computers within these blocks?
(iii) Suggest the placement of a Repeater in the network with justification.
(iv) The organization is planning to link its office to an office in the hilly areas. Suggest a way to
connect it economically. Justify your answer.
33. Mr. Sharma is trying to write a code to plot the line graph. Write a python code to create the given
chart. Give suitable title for x and y axis.
or
Write a program to plot a bar chart to depict the changing weekly onion prices for four weeks. Give
appropriate axes labels.
Week = [1,2,3,4]
Price = [40,80,100,70]
Section E
34. Shreya, a database administrator has designed a database for a clothing shop. Help her by writing
answers of the following questions based on the given table:
CLOTHS