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

IP Sample Paper 8

Xvbb

Uploaded by

santro9776
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
112 views10 pages

IP Sample Paper 8

Xvbb

Uploaded by

santro9776
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 10

Page 1 Sample Paper 8 INFORMATICS PRACTICES Class 12

Sample Paper 8
INFORMATICS PRACTICES (065)
CLASS XII 2023-24
Time: 3 Hours Max. Marks: 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
1. Which function returns the length of the string in bytes?
(a) LENGTH ( ) (b) DATE ( )
(c) TIME ( ) (d) MATH ( )

2. Which of the following function is used to create DataFrame?


(a) DataFrame( ) (b) NewFrame( )
(c) CreateDataFrame( ) (d) None of these

3. A software which is available for free and the code is open for all, it is called as _____.
(a) Proprietary software (b) Free and open source software
(c) Free software (d) None of these

4. In India, e-Waste management assumes greater significance because


(a) generation of own e-Waste
(b) dumping of e-Waste from developed countries
(c) lack of awareness
(d) All of these

5. As soon we get any good news from any source in social media:
(a) We should forward to many people so that they can be benefited.
(b) We should never forward to anyone.
(c) We should confirm the news from any reliable source before forwarding.
(d) We should forward to our family and friends only.

Install NODIA App to See the Solutions.


Click Here To Install
Page 2 Sample Paper 8 INFORMATICS PRACTICES Class 12

6. Abhishek uses computer and mobile for his personal use. He uploaded one video on his youtube channel, where he
used one background music downloaded from somewhere on Internet, he may be violating _____.
(a) copyright (b) intellectual property right
(c) plagiarism (d) None of these

7. _____ is a set of moral principles that governs the behaviour of a group or an individual and regulates the use of
computers.
(a) Copyright (b) Computer ethics
(c) Property rights (d) Privacy law

8. Write the output of the following SQL command.


SELECT ROUND(47.89);
(a) 47.88 (b) 47.8
(c) 48.0 (d) 50

9. Identify single-row functions of MySQL amongst the following]


(a) TRIM() (b) MAX()
(c) ROUND() (d) Both (a) and (c)

10. Method or function to add a new row in a DataFrame is _____.


(a) .loc() (b) .iloc()
(c) join() (d) add()

11. series1 = pd.Series ({‘India’ : ‘New Delhi’, ‘UK’ : ‘London’, ‘Japan’ : ‘Tokyo’})
print(series1)
Above code is an example of
(a) creating series from dictionary (b) creating series from scalar values
(c) creating series from an array (d) creating series from tuple

12. _____ refers to a small, single site network.


(a) DSL (b) RAM
(c) WAN (d) PAN

13. _____ network topology in which there are bi-directional links between each possible node.
(a) Ring (b) Mesh
(c) Tree (d) None of these

14. Which of the following is not a Mathematical function?


(a) LENGTH() (b) POWER()
(c) MOD() (d) ROUND()

15. Which SQL clause is used to restrict the rows returned by a query?
(a) SELECT (b) ORDER BY
(c) WHERE (d) GROUP BY

Install NODIA App to See the Solutions.


Click Here To Install
Page 3 Sample Paper 8 INFORMATICS PRACTICES Class 12

16. Consider a table DOCTOR(ID, DocName, Department, DOJ, Gender, Salary). Which of the following query will
display the names and salaries of doctors in descending order of salaries.
(a) SELECT DocName, Salary FROM DOCTOR ORDER BY Salary DESC;
(b) SELECT DocName, Salary FROM DOCTOR WHERE ORDER BY Salary ASC;
(c) SELECT DocName, Salary FROM DOCTOR ORDER BY Salary ASC;
(d) SELECT DocName, Salary FROM DOCTOR WHERE ORDER BY Salary DESC;

Directions (Q.Nos. 17-18) : Assertion and Reason based Questions.

17. Assertion (A) Star topology is a network layout in which all devices are connected to a central hub or switch.
Reason (R) The central hub acts as a central point of communication and controls the flow of data between devices.
(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 and R is true.

18. Assertion (A) Sorting is the operation to arrange data in a specific order, sort_values()function used to perform the
operation.
Reason (R) Row wise sorting cannot be performed in Python DataFrame objects.
(a) Both A and R are true and R is the correct explanation of A.
(b) Both A and R are true and R is not the correct explanation of R.
(c) A is true but R is false.
(d) Both A and R are false.

Section B
19. Given a DataFrame created as:
import pandas as p
Stud=p.Series({‘Name’:[‘Ria’,
‘Priya’, ‘Jack’], ‘Eco’:[56,67,89],
‘IP’:[90,87,45], ‘Eng’:[58,78,32]})
Studdf=p.DataFrame(Stud)
print(Studdf[0:2])
What will be the output of the above code?

20. The Python code written below has syntactical errors. Rewrite the correct code and underline the corrections made.
import pandas as pd
data1 = {ID [1, 2, 3], Name [Riya,
Preeti, Neeta]}
data2 = {ID [4, 5, 6], Name [Siya,
Pratik, Neeraj]}
df1 = pd.DataFrame(data1)

Install NODIA App to See the Solutions.


Click Here To Install
Page 4 Sample Paper 8 INFORMATICS PRACTICES Class 12

df2 = pd.DataFrame(data2)
result = pd.concat(df1, df2)
print()

21. Complete the given Python code to calculate the mean value of the ‘price’ column in the DataFrame ‘df’.
import _____ as pd
df = pd.DataFrame(‘item’ : [‘A’, ‘B’,
‘C’, ‘D’], ‘price’: [50, 30,
45, 20]})
mean_price = df[‘price’]_____()
print(mean_price)

22. Which SQL function is used to remove leading and trailing spaces from a character expression X, where X =
‘LEARNING ###MYSQL####’ (# denotes a blank space) and also give the output of X.

23. Which type of MySQL function accepts only numeric values? Give the name of some functions of that type.

24. What do you mean by spyware?

25. What do you mean by network topology? Write different types of topology.
 o
Mr. Chandervardhan is not able to identify the domain name in the given URL. Identify and write it for him. Also,
explain what is URL?
http://www.cbsenic.in/aboutus.htm

Section C
26.
Year Month Passengers
0 2010 Jan 25
1 2010 Mar 50
2 2012 Jan 35
3 2010 Dec 55
4 2012 Dec 65
Write the code to create the above DataFrame:

27. Write an SQL command to create the table BANK whose structure is given below
FieldName Data type Size Constraint

ID_Number integer 10 Primary key


Name varchar 20
B_Date date

Install NODIA App to See the Solutions.


Click Here To Install
Page 5 Sample Paper 8 INFORMATICS PRACTICES Class 12

Address varchar 50

28. Abhishek uses computer and mobile for his personal use. Study the following cases and answer the questions given
below.
(a) Once he got the message in Whatsapp that CBSE is announcing the result of class XII tomorrow at 12:00 pm.
He forwarded the message to his few friends. But later, he came to know that no such announcement was there
in CBSE official website. In this case, he violated_____.
(b) He is getting abuse messages from an unknown number due to which he is thinking of quarreling with that
person. The unknown person can be called as _____.
(c) He registered himself in one website by giving his email id and phone number he is leaving _____.
 o
Write some symptoms of a malware attack.

29. Consider the following DataFrame df :


Code Name Price Qty Discount
0 C1 ABC 5500 10 10
1 C2 XYZ 4500 8 5
2 C3 PQR 5200 12 8
3 C4 MNO 3000 9 15
4 C5 LMN 5500 11 12
(i) Write down the command that will give the following output.
Code C1
Name ABC
Price 3000
Qty 8
Discount 5
dtype : object
(ii) Find the most repeat value of a given set of number of DataFrame.
(iii) To sort the index label of DataFrame df in descending order.

30. Mr. Manav, a database administrator in “Global Educational and Training Institute” has created following table
named “Training” for the upcoming training schedule:
Table : Training
Training_Id Name Email Id Topic City Fee

ND01 Mr. Rajan raj@gmail. corn Cyber Security New Delhi 10000

GU01 Ms. Urvashi [email protected] ICT in Education Gurugram 15000

FD01 Ms. Neena neenarediff.com Cyber Security Faridabad 12000

Install NODIA App to See the Solutions.


Click Here To Install
Page 6 Sample Paper 8 INFORMATICS PRACTICES Class 12

ND02 Mr. Vinay NULL ICT in Education New Delhi 13000

GU02 Mr. Naveen [email protected] Cyber Security Gurugram NULL


Predict the output of the following queries:
(i) SELECT SUBSTR(City, 2, 4) FROM Training WHERE Topic!= ‘Cyber Security’;
(ii) SELECT NAME FROM Training WHERE INSTR (Email_Id, ‘@’)=0;
(iii) SELECT Topic , COUNT(*) FROM Training GROUP BY Topic;
 o
Shanya Kumar is working with the following table Customers:
Table : Customers
CNO CNAME CITIES
C1 SANYAM DELHI
C2 SHRUTI DELHI
C3 MEHER MUMBAI
C4 SAKSHI CHENNAI
C5 RITESH INDORE
C6 RAHUL DELHI
C7 AMEER CHENNAI
C8 MINAKSHI BANGLORE
C9 ANSHUL MUMBAI

Write the queries for the following:


(i) To display the city names in lower case letter whose CNO is either C5 or C9.
(ii) To display the length of Customer’s name for those Customers whose NAME end with R or L.
(iii) To display the Customer’s name and their respective CITIES merged together for all the Customers whose CNO
is ending with 8.

Section D
31. Consider the following table named “Product”, showing details of products being sold in a grocery shop.
Table : Product
PCode PName UPrice Manufacture
P01 Washing Powder 120 Surf
P02 Tooth Paste 54 Colgate
P03 Soap 25 Lux
P04 Tooth Paste 65 Pepsodent
P05 Soap 38 Dove
P06 Shampoo 245 Dove

Write SQL queries for the following and output(s) produced by executing the following queries on the basis of the
information given above in the table Product.
(i) Create the table Product with appropriate data types and constraints.

Install NODIA App to See the Solutions.


Click Here To Install
Page 7 Sample Paper 8 INFORMATICS PRACTICES Class 12

(ii) Identify the PRIMARY KEY in table Product.


(iii) List the Product Code, product Name and Price in with their Product Name for all Dove Manufacture.
(iv) Increase the Price by 12 per.cent for all the products manufactured by Dove.

32. Mr. Krishnamurthy, who is a new user of Python Pandas, has created the following Series “Electrical” carrying
names of electrical appliances as values and their wattage as the index. He wants to perform certain operations on
the Series . You are supposed to help him in writing the commands :
Electrical
Index Name
12W LED
200W Fan
1000W Electric Iron
1200W Rice Cooker

(i) He wants to change the index of Electrical series “LED” element to “A”.
(ii) To display the record of ‘Fan”.
(iii) Remove dataset with index 1000 W.
 (Option for part (iii) only)
o
Display the last rows of the dataset.

Section E
33. Consider the following graph. Write the code to plot it.

 o

Install NODIA App to See the Solutions.


Click Here To Install
Page 8 Sample Paper 8 INFORMATICS PRACTICES Class 12

Draw the following bar graph representing the quantity of items in each month.

34. Consider the following table Graduate and write SQL commands for (i) to (v).
Table : Graduate
SNo Name Stipend Subject Average Div
1 Karan 400 Physics 68 1
2 Divakar 450 Computers 68 1
3 Divya 300 Chemistry 62 2
4 Arun 350 Physics 63 1
5 Sabina 500 Mathematics 70 1
6 John 400 Chemistry 55 2
7 Robert 250 Physics 64 1
8 Rubina 450 Mathematics 68 1
9 Vikas 500 Computers 62 1
10 Mohan 300 Mathematics 57 2

(i) List the Names of those students who obtained Div 1.

(ii) Display a report, listing Name, Stipend, Subject and amount of stipend received in a year assuming that the
Stipend is paid every month.

(iii) Display first three characters of student Name where/whose SNo is 7.

(iv) Display the student Names having 2nd division.

(v) Display division wise Name of students in alphabetical order.

 o

Write SQL queries for the questions from (i) to (v) on the basis of table Class.

Install NODIA App to See the Solutions.


Click Here To Install
Page 9 Sample Paper 8 INFORMATICS PRACTICES Class 12

No Name Stipend Subject AvgMark Grade

01 Vikas 1200 Medical 67 B

02 Boby 1400 Humanities 78.4 B

03 Tarun 1000 Medical 64.8 C

04 Varun 1600 Non-medical 84 A

05 Atul 1800 Non-medical 92 A

(i) Select all the non-medical stream students from the table Class.
(ii) Arrange the records of Class name wise.
(iii) List the records whose grade is B or C.
(iv) Insert the new row with the following data. (06, ‘Jack’, 2800, ‘Humanities’, 98, ‘A’)
(v) Identify the attribute to be best suitable for primary key.

35. A company in Mega Enterprises has 4 wings of buildings as shown in the diagram :

Centre to centre distances between various buildings:


W3 to W1 – 50m
W1 to W2 – 60m
W2 to W4 – 25m
W4 to W3 – 170 m
W3 to W2 – 125 m
W1 to W4 – 90 m
Number of computers in each of the wing:

Install NODIA App to See the Solutions.


Click Here To Install
Page 10 Sample Paper 8 INFORMATICS PRACTICES Class 12

W1 – 150
W2 – 15
W3 – 15
W4 – 25

Computers in each wing are networked but wings are not networked. The company has now decided to connect the
wings also.

(i) Suggest a most suitable cable layout for the above connections.

(ii) Suggest the most appropriate topology of the connection between the wings.

(iii) Suggest the placement of the following devices with justification, if the company wants minimised network
traffic.

(a) Repeater (b) Hub/Switch

(iv) Expand the following terms:

(a) HTTP (b)TCP/IP

(v) Suggest the suitable wing to house the server.

 EN

Install NODIA App to See the Solutions.


Click Here To Install

You might also like