0% found this document useful (0 votes)
3 views10 pages

XII IP Pre Board 2024 QP Setee

Download as pdf or txt
Download as pdf or txt
Download as pdf or txt
You are on page 1/ 10

KENDRIYA VIDYALAYA SANGATHAN AGRA REGION

FIRST PRE-BOARD EXAMINATION 2024-25


Informatics Practices (065)
Time Allowed : 3 Hours Class: XIIth Max. Marks : 70
General Instructions:
● Please check this question paper contains 37 questions.
● All questions are compulsory. However, internal choices have been provided in some
questions. Attempt only one of the choices in such questions
● The paper is divided into 5 Sections- A, B, C, D and E.
● Section A consists of 21 questions (1 to 21). Each question carries 1 Mark.
● Section B consists of 7 questions (22 to 28). Each question carries 2 Marks.
● Section C consists of 4 questions (29 to 32). Each question carries 3 Marks.
● Section D consists of 2 case study type questions (33 to 34). Each question 4 Marks.
● Section E consists of 3 questions (35 to 37). Each question carries 5 Marks.
● All programming questions are to be answered using Python Language only.
● In case of MCQ, text of the correct answer should also be written.
Q. No. Section-A (21 x 1 = 21 Marks) Marks

1. To create an empty Series object, you can use: 1


(a) pd.Series(empty) (b) pd.Series( )
(c) pd.Series(np.NaN) (d) all of these

2. Which one of the following functions is used to count the no of rows from the given 1
table in MySQL?
(a) COUNT(* ) (b) CARDINALITY( )
(c) COUNT(Column name ) (d) All the above

3. A _______________ is a network device that can receive the data, analyse it and 1
transmit it to other networks.
(a) Modem (b) Hub (c) Repeater (d) Router

4. Which MySQL command helps to add a primary key constraint to any table that has 1
already been created ?
(a) UPDATE (b) INSERT INTO (c) ALTER TABLE (d) ORDER BY

5. Which of the following is Net Etiquette? 1


(a) Be Ethical (b) Be Responsible (c) Be Respectful (d) All of the above

Page No. 1 of 10
6. In given code dataframe ‘D1’ has _____ rows and _____ columns. 1
import pandas as pd
S1 = pd.Series([1, 2, 3, 4], index = ['a', 'b','c','d'])
S2 = pd.Series([11, 22, 33, 44], index = ['a', 'bb','c','dd'])
D1 = pd.DataFrame([S1,S2])
(a) 2, 4 (b) 4, 6 (c) 4, 4 (d) 2, 6

7. By default, the plot() function of Matplotlib draws a ______ plot. 1


(a) histogram (b) column (c) bar (d) line

8. _______________ helps to fetch a group of rows based on common values in a 1


column.
(a) ORDER BY (b) FILTER (c) GROUP BY (d) SELECT BY

9. Identify the function used for reading data from a csv file. 1
(a) read.csv() (b) read_csv() (c) read_data() (d) csv_read()

10. ______________ is the gaining of unauthorized access to data in a computer 1


system.
(a) Phishing (b) Plagiarism (c) Hacking (d) Copyright violation

11. Which of the following keywords will you use in the following query to display the 1
unique values of the column dept_name?
SELECT________ dept_name FROM COMPANY;
(a) All (b) From (c) Distinct (d) Unique

12. . Which of the following Internet services is used for instant messaging ? 1
(a) Chat (b ) Email (c) WWW (d) Python

13. Which of the following command is used to display first three rows of a DataFrame 1
'DF' ?
(a) DF.head() (b) DF.header() (c) DF.head(3) (d) DF.Head(3)

14. By restricting the server and encrypting the data, a software company's server is 1
unethically accessed in order to obtain sensitive information. The attacker blackmails
the company to pay money for getting access to the data, and threatens to publish
sensitive information unless price is paid. This kind of attack is known as:
(a) Phishing (b) Identity Theft (c) Plagiarism (d) Ransomware

Page No. 2 of 10
15. In Python Pandas, head(n) method returns the first n members of the series. What is 1
the default value of n ?
(a) 2 (b) 3 (c) 4 (d) 5

16. What will be the output of the following query ? 1


SELECT POWER(2,MOD(17,3));
(a) 8 (b) 1 (c) 0 (d) 4

17. 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 (b) 0
2 Banana 2 Orange
(c) 0 (d) Empty DataFrame
2 Banana Columns:[0]
4 Grapes Index:[ ]

18. The command used to give a heading to a graph using matplot is ______ 1
(a) plt.show() (b) plt.plot() (c) plt.xlabel() (d) plt.title()

19. Which type of network covers a geographical area like a city or town? 1
(a) LAN (b) MAN (c) WAN (d) PAN

Q-20 and Q-21 are Assertion (A) and Reason (R) Type questions. Choose the correct
option as:
(a) Both Assertion (A) and Reason (R) are true, and Reason (R) is the correct
explanation of Assertion (A)
(b) Both Assertion (A) and Reason (R) are true, but Reason (R) is not the correct
explanation of Assertion (A)
(c) Assertion (A) is True, but Reason (R) is False
(d) Assertion (A) is False, but Reason (R) is True

20. Assertion (A):- DataFrame has both a row and column index. 1
Reasoning (R): - A DataFrame is a two-dimensional labelled data structure like a
table of MySQL.

21. Assertion (A): In SQL, UPDATE is a Data Definition Language (DDL) Command. 1

Page No. 3 of 10
Reason (R): DDL commands are used to create, modify, or remove database
structures, such as tables.

Section-B (7 x 2 = 14 Marks)

22. What is a Series in Python Pandas? Also, give a suitable example to support your 2
answer.
OR
What does the term 'library' signify in Python? Mention one use for each of the
following libraries:
• Pandas
• Matplotlib

23. Differentiate between the active digital footprint and passive digital footprints. 2

24. Consider the string: "Kendriya Vidyalaya Sangathan". 2


Write suitable SQL queries for the following:
(a) To extract and display "Vidyalaya" from the string.
(b) Display the position of the first occurrence of "Sangathan" in the given string

25. Briefly explain the basic concepts of a web server and web hosting. 2
OR
Ravi is doing a course in networking. He is unable to understand the concept of URL.
Help him by explaining it with the help of suitable example.

26. Write any two differences between DELETE and DROP TABLE command of MySQL. 2

27. Explain plagiarism with an example. 2

28. The Python code written below has syntactical errors. Rewrite the correct code and 2
underline the correction(s) made.
import Pandas as pd
countries=[{'country' ; 'INDIA', 'capital' : 'New Delhi'},
{'country' : 'USA', 'capital' : 'New York'},
{'country' : 'JAPAN', 'capital' : 'Tokyo'}
df=pd.DataFrame(country)
print(df)
OR
Complete the given Python code to get the required output as: Rajasthan
import _________ as pd

Page No. 4 of 10
di = {'Corbett': 'Uttarakhand', 'Sariska': 'Rajasthan', 'Kanha': 'Madhya Pradesh’,
'Gir':'Gujarat'}
NP = ___________. Series( _____ )
print(NP[ ___________ ])

Section-C (4 x 3 = 12 Marks)

29. Richa, recently started using her social media account. Within a few days, she 3
befriends many people she knows and some that she does not know. After some time,
she starts getting negative comments on her posts. She also finds that her pictures are
being shared online without her permission. Based on the given information, answer
the questions given below.
(a) Identify the type of cybercrime she is a victim of.
(b) Under which act, she can lodge a complaint to the relevant authorities?
(c) Suggest her any two precautionary measures which she should take in future
while being online to avoid any such situations.

30. Kabir, a data analyst, has stored the voter's name and age in a dictionary. Now, Kabir 3
wants to create a list of dictionaries to store data of multiple voters. He also wants to
create a DataFrame from the same list of dictionaries having appropriate row labels
as shown below :
Voter Name Voter_Age
Ar1001 Arjun 35
Ba3002 Bala 23
Go4002 Govind 25
Dh4007 Dhruv 19
Na6005 Navya 18
Help Kabir in writing a Python program to complete the task.
OR
Write a Python Program to create a Pandas Series as shown below using a
dictionary. Note that the left column indicates the indices and the right column
displays the data.
Ravi Delhi
Rahul Noida
Amit Agra

Page No. 5 of 10
31. Write MySQL statements for the following: 3
(a) To create a database named FOOD.
(b) To create a table named Nutrients based on the following specification:

Column Name Data Type Constraints


Food_Item Varchar(20) Primary Key
Calorie Integer

32. Consider the following tables: 3


Table: EMP
EMPNO ENAME JOB SAL DEPTNO
101 Rohit Manager 110000 10
102 Juber Clerk 60000 20
103 Manoj Clerk 65000 10

Table: DEPT
DEPTNO DEPTNAME
10 Production
20 Sales

Write appropriate SQL queries for the following:


(a) Display Job-wise average Salary.
(b) List all Employee Name in the decreasing order of Salary.
(c) Display employee name along with their corresponding department Name.
OR
Consider the following tables:
Table: STU
RNO SNAME CITY MARKS STREAM_NO
1 Arun DELHI 220 1
2 Sahil AGRA 210 2
3 Pooja DELHI 230 1

Table: STREAM
STREAM_NO STREAM_NAME
1 Science
2 Commerce

Page No. 6 of 10
Write appropriate SQL queries for the following:
(a) Display the city-wise total marks.
(b) Display the names of all the Students in uppercase whose belongs to DELHI.
(c) Display the Students name along with their corresponding Stream Name

Section-D (2 x 4 = 8 Marks)

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

He is trying to write a code to plot the graph. Help Mr. Sharma to fill in the blanks of
the code and get the desired output.
import__________________________ #Statement 1
Games=["Subway Surfer","Temple Run","Candy Crush","Bottle Shot","Runner Best"]
Rating=[4.2,4.8,5.0,3.8,4.1]
plt.______________(Games,Rating) #Statement 2
plt.xlabel("Games")
plt.______________("Rating") #Statement 3
plt._______________ #Statement 4
(a) Write the suitable code for the import statement in the blank space in the line
marked as Statement-1.

Page No. 7 of 10
(b) Refer to the graph shown above and fill in the blank in Statement-2 with
suitable Python code.
(c) Fill in the blank in Statement-3 with the name of the function to set the label on
the y-axis.
(d) Fill in the blank in Statement-4 with the name of function/method to display
the graph.

34. Based on the SQL table CAR_SALES, write suitable queries for the following: 4

(a) Display fuel wise average sales in the first quarter.


(b) Display segment wise highest sales in the second quarter.
(c) Display the records in the descending order of sales in the second quarter.
(d) Display Segment in lowercase.

OR

Predict the output of the following queries based on the table CAR_SALES given
above:
(a) SELECT LEFT(SEGMENT,2) FROM CAR_SALES WHERE FUEL=
"PETROL";
(b) SELECT (QT2-QT1)/2 "AVG SALE" FROM CAR_SALES WHERE
SEGMENT= "SUV";
(c) SELECT SUM(QT1) "TOT SALE" FROM CAR_SALES WHERE FUEL=
"DIESEL";
(d) Select LENGTH(SEGMENT) from CAR_SALES where QT1< 5000;
Section-E (3 x 5 = 15 Marks)

35. “NEXTGEN CLASSES” is located in Jaipur and is planning to go in for 5


networking of four wings for better interaction. The details are as shown below

Page No. 8 of 10
Student Wing Hostel Wing

Admin Wing Admission Wing

The distance between various wings are :


Student to Admin 265m
Student to Admission 495m
Student to Hostel 525m
Admission to Admin 200m
Admission to Hostel 195m
Admin to Hostel 325m
Number of computers are :
Student Wing 312
Admission Wing 156
Admin Wing 26
Hostel Wing 125

(i) Suggest the most suitable place (i.e. Wing) to install the server of this
organization with a suitable reason.
(ii) Suggest an ideal layout for connecting all Wings. Also write the type of
Topology.
(iii) Suggest the placement of the following devices with reasons :
a) Modem b) Switch
(iv) The Institute is planning to link its another branch “ABHI CLASSES” in Andaman
& Nicobar. Suggest the type of network (LAN, MAN, WAN) and a fast and very
effective wireless transmission medium to connect it with Jaipur, reasonably
high speed is required, cost is not the factor. Justify your answer.
(v) Suggest a protocol that shall be needed to provide Video Conferencing solution
between Jaipur and Andaman.

Page No. 9 of 10
36. Ekam, a Data Analyst with a multinational brand has designed the DataFrame df that 5
contains the four quarter’s sales data of different stores as shown below:
Store Qtr1 Qtr2 Qtr3 Qtr4
0 Store1 300 240 450 230
1 Store2 350 340 403 210
2 Store3 250 180 145 160
Answer the following questions:
(a) Predict the output of the following python statement:
(i) print(df.size)
(ii) print(df[1:3])
(b) Delete the last row from the DataFrame.
(c) Write Python statement to add a new column Total_Sales which is the addition of
all the 4 quarter sales.
(d) Rename the column name 'Store' to 'StoreName'
(e) Write Python statement to export the DataFrame to a CSV file named data.csv
stored at D: drive

37. Write the SQL queries which will perform the following operations : 5
(a) To display the day part from your date of admission, which is ‘2024-10-13’.
(b) To convert your father’s email id ‘xyz@abc.com’ to uppercase.
(c) To count the number of characters in the string ‘India’.
(d) To display today’s day name i.e., Sunday or Monday …
(e) To display your height 5.41 after rounding off to 1 decimal place.
OR
Write suitable SQL queries for the following:
(a) To calculate the exponent for 3 raised to the power of 4.
(b) To display current date and time.
(c) To round off the value -34.4567 to 2 decimal place.
(d) To remove all the probable leading and trailing spaces from the column userid
of the table named user.
(e) To display the length of the string ‘FIFA World Cup’.

Page No. 10 of 10

You might also like