CBSE Sample Papers for Class 12 Informatics Practices Set 11 with Solutions

Students must start practicing the questions from CBSE Sample Papers for Class 12 Informatics Practices with Solutions Set 11 are designed as per the revised syllabus.

CBSE Sample Papers for Class 12 Informatics Practices Set 11 with Solutions

Time Allowed: 3 hours
Maximum 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

Question 1.
Rohit forgot his laptop in his car and when he came back, he found his laptop was missing. This act is _____.
(a) cybercrime
(b) phishing
(c) theft
(d) plagiarism [1]Answer:
(c) theft

Question 2.
The rights of the owner of information to decide, how much information is to be shared/exchanged/distributed, are collectively known as ……… [1](a) Intelligent Portable Rights
(b) Intellectual Property Rights
(c) Interactive Property Rights
(d) Instance Portability Rights
(b) Intellectual Property Rights

Question 3.
Which of the following statement(s) is/are incorrect? [1](a) A column of a DataFrame can be deleted.
(b) A column of a DataFrame can be deleted, if it carries no data.
(c) A column of a DataFrame can be deleted, if it carries NaN values.
(d) Columns of DataFrame cannot be deleted.
(d) Columns of DataFrames cannot be deleted.

Question 4.
Electronic discovery technique used to determine and reveal technical criminal evidence is called ____. [1](a) cyber investigation
(b) cyber evidence
(c) cyber forensics
(d) cyber intrude
(c) cyber forensics

Question 5.
The HAVING clause acts like a WHERE clause, but it identifies columns that meet a criterion, rather than rows.
(a) True
(b) False
(c) Depend on query
(d) Depend on column
(a) True

Question 6.
A series is created with 5 integers as [1]

import pandas as pd

Find the output of the above code.
(a) 15
(b) 10
(c) 20
(d) 25
(c) 20

Question 7.
The term phishing is synonymous to the term [1](a) spoofing
(b) spooling
(c) stalking
(d) None of these
(a) spoofing

Question 8.
While creating a DataFrame Sunil wanted to specify the datatype, ____ property will help him to do so. [1](a) datatype
(b) type
(c) dtype
(d) dt
(c) dtype

Question 9.
What does the web server need to send back information to the user? [1](a) Home address
(b) Domain name
(c) IP address
(d) Both (b) and (c)
(d) Both (b) and (c)

Question 10.
SELECT ………. (Calorie) FROM Food WHERE NOT type = “Protein”; [1]Requirement; To get the average calories of non-protein type foods.
Select the appropriate function to complete the above query.
(a) Mean
(b) Min
(c) AVG
(d) Sum
(c) AVG

Question 11.
____ device may operate at different network speeds depending on the protocol standard they support. [1](a) Router
(b) Ethernet card
(c) RJ45 Connector
(d) None of these
(b) Ethernet card

Question 12.
Help Ritesh to write the command to display the name of the youngest student. [1](a) SELECT Name, MIN(DOB) FROM Student;
(b) SELECT Name, MAX(DOB) FROM Student;
(c) SELECT Name, MIN(DOB) FROM Student GROUP BY Name;
(b) SELECT Name, MAX(DOB) FROM Student

Question 13.
Which of the following statements is incorrect in the context of a worm? [1](a) It represents a category of malware
(b) It creates infections in a computer
(c) It is self replicating
(d) It cannot travel on its own
(d) It cannot travel on its own

Question 14.
In MySQL which function is used to find the round off value of the specified floating point number? [1](a) FLOAT()
(c) ROUND()
(c) ROUND()

Question 15.
Which of the following operators compare two conditions at a time to determine whether a row can be selected for the output? [1](a) Comparison operators
(b) Logical operators
(c) Arithmetic operators
(d) Between operator
(a) Comparison operators

Question 16.
Which of the following commands is not a data manipulation command? [1](a) SELECT

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

Question 17.
Assertion (A) Web Browser is application software that allows us to view and explore information on the web. [1]Reason (R) Web browser can show text, audio, video, animation and more. It is the responsibility of a web browser to interpret text and commands contained in the web page.
(a) Both A and R are true and R is the correct explanation of A.
(b) Both A and R are true but R is not the correct explanation of A.
(c) A is true but R is false.
(d) A is false but R is true.
(a) Both A and R are true and R is the correct explanation for A.

Question 18.
Assertion (A) Some time we want to combine the two DataFrame using the merge() function. [1]Reason (R) Merging operation can be performed only with common values of column not with specific column.
(a) Both A and R are true and R is the correct explanation of A.
(b) Both A and R are true but R is not the correct explanation of A.
(c) A is true but R is false.
(d) A is false but R is true.
(c) A is true but R is false.

The joining is performed on columns or indexes. If the joining is done on columns, indexes are ignored. We can specify the column names to use for merging using “on” parameter.

Section – B

Question 19.
Identify the following devices [2](i) An intelligent device that connects several nodes to form a network and redirects the received information only to intended node(s).
(ii) A device that regenerates (amplifies) the received signal and re-transmits it to its destinations.


What is a modem?
(i) Switch
(ii) Repeater


Modem stands for Modulator/Demodulator, which converts analog signal into digital signal and again digital signal into analog signal. It is used to connect the computers and transmit data using telephone lines.

Question 20.
Prachi has given the following command to obtain the highest marks: [2]


But she is not getting the desired result. Help her by writing the correct command.

SELECT Class, MAX(Marks) FROM Student GROUP BY Class;

Question 21.
Write a query to display the Sum, Average, Highest and Lowest marks of the students grouped by subject and sub-grouped by class. [2]Answer:

mysql> SELECT SUM (marks), AVG (marks), MAX (marks), MIN (marks) FROM students
GROUP BY subject, class ;

Question 22.
The Python code written below has syntactical errors. Rewrite the correct code and underline the corrections made. [2]

import pandas as Pd
data = {Name ['Alice', 'Bob', 'Charlie'], Age [25, 30, 22]}
df = pd.DataFrame(Data)
df['Country'] = ['USA', 'Canada', 'UK']


import pandas pd
data = {‘Name’: [‘Alice’, ‘Bob', Charlie’], ‘Age’: [25, 30, 22]}
df = pd.DataFrame(data)
df[’Country’] = [‘USA’, ‘Canada’, ‘UK]

Question 23.
For avoiding the plagiarism, what guidelines should we follow? [2]Answer:
Follow the below guidelines to avoid plagiarism:

  1. To avoid plagiarism, instead of copying the language of the book as it is, try to put it is your own language/words.
  2. One should have a clear understanding of plagiarism and its consequences, so that no one perform it unintentionally.
  3. If copying someone else’s work in our task, word for word, then do not forget enclosing it is quotes and also mention its source.
  4. Another way is to credit, the author has rights which was useful for your task and not taking credit for its yourself.

Question 24.
Given a DataFrame gradedf: [2]

import pandas as pd
gradedf=pd.DataFrame({‘Name’:[‘Rashmi ’, ‘Ani’, ‘Sunil’, ‘Becker’], ‘Grade’ : [‘A’, 'B‘, 'C’, ‘D’]
print (gradedf.iloc[0 : 2])

Find the output.

Name Grade
0 Rashmi A
1 Ani B

Question 25.
Complete the given Python code: to rename the column Age to Years in the DataFrame df and display the update DataFrame.

import ____ as pd
df = pd.DataFrame({'Name': ['John', 'Alice', ’Bob'], 'Age': [25, 30, 22]})
df.____(columns={ 'Age': ___ })


import pandas as pd
df = pd.DataFrane({’Name’: [‘John’, ‘Alice’, ‘Bob’], ‘Age’: [25, 30, 22]))
df = df.rename(colunins={’Age’: Years’})

Section – C

Question 26.
(i) Write a query to display current date on your system. [3](ii) Display the position of occurrence of string “OR” in the string “CORPORATE LAWYER”
(iii) Mrs. Kumar is using table Students with the following columns;
Rno, AdmNo, Name, Aggregate, display all information of students in descending order of name and with ascending order of aggregate.


Which commands are used to control user’s privileges and how?
(i) mysql> SELECT CURDATE( );


Two commands are used to control a user’s privileges

  1. GRANT

The GRANT command is used to give an existing user privileges, and REVOKE is used to remove privileges of a user
does not exist, GRANT will create a new user at the same time and give them all privileges.

Question 27.
Write a Python program to create the DataFrame with name dfballs from dictionary of different colors of balls Red, Green and Yellow with data values[10, 20, 30], [30, 40, 50] and [90, 100, 110]. [3]Answer:

import pandas as pd
dfBalls=pd.DataFrame({‘Red’ :[10, 20, 30], ‘Green’:[30, 40, 50), ‘Yellow’ :[90, 100, 110]})
print (dfBalls)

Question 28.
Given a DataFrame “Cellphone’’ containing the following data: [3]

Index ModelNo Type Brand
0 A22 4G Samsung
1 N95 3G Nokia
2 XPS12 2G Apple

Write the Python statements to do the following:
(i) To remove the first row
(ii) The command that changes the Brand column to values [‘Realme’, ‘Xiomi’,’Samsung’](iii) To save the dataframe to a CSV file “Mobiles.csv”
(i) Cellphone,drop(0)
(ii) Cellphone[’Brand’] = [‘Realme’, ‘Xiomi ‘ ,‘Samsung’](iii) Cellphone.to_csv(‘Mobiles.csv’)

Question 29.
Jack received a phone call stating that the call was from his Bank and they asked him his ATM card and PIN number. Also his colleague Jennifer was trying to see his key locations of fingers on the keyboard, while he was trying to open his E-mail account. [3](i) What this call may be …………..?
(ii) What is the symbol © used for ?
(iii) What kind of network threat is Jennifer trying to do?


List the advantages of recycling the e-Waste.
(i) case of phishing
(ii) right to copy
(iii) Snooping


Some advantages of recycling the e-Waste are as follows.

  1. Conserves Natural Resources
  2. Protects Environment
  3. Create Jobs
  4. Saves Landfill Space
  5. Save Money

Question 30.
Predict the output of the following. [3](i) SELECT POW (INSTR(“Success@dedication”, “@”), 2);
(ii) SELECT MONTH(“2020-11-15”)*POW(2, 3);
(iii) LTRIM(“ Python Basics ’’)
(i) 64
(ii) 88
(iii) “Python Basics

Section – D

Question 31.
Consider the following table MASTER. [4]Table: MASTER

SNo Name Age Department Salary
1 Shyam 21 Computer 12000
2 Shiv 25 Maths 15000
3 Rakesh 31 Hindi 14000
4 Sharmila 32 History 20000
5 Dushyant 25 Software 30000

(i) Write a command to update the salary of the employee to 40000, whose SNo is 3.
(ii) Write a query to add a column Date_of_ Joining to the table MASTER.
(iii) Write a query to display Age and Department of those employees whose salary is greater than 12000.
(iv) Write a query to display Name whose Salary is more than 15000 and Department is Computer.
(i) UPDATE MASTER SET Salary= 40000 WHERE SNo =3;
(ii) ALTER TABLE MASTER ADD Date_of_Joining Date;
(iii) SELECT Age, Department FROM MASTER WHERE Salary>12000;
(iv) SELECT Name FROM MASTER WHERE Department = Computer” AND Salary > 15000;

Question 32.
Given the following code, where a series is created storing population of some cities: [4]import pandas as pd
popseries=pd.Series([34567, 890, 450, 678, 900])

(a) What will be the output of following commands?
(i) print(popseries.tail(3).head(2))
(ii) print(popseries/2)
(b) Write the Python statement to display the elements of dataset with value above 500.
(c) Write Python statement for the required output (5,)


(Option for part (c) only)
Write Python statement to assign index to the series as 11, 12, 13, 14, 15.


0 17283.5
1 445.0
2 225.0
3 339.0
4 450.0

(b) print(popseries[popseries>500J)
(c) popseries.shape


popseries.index=[11, 12, 13, 14, 15]

Section – E

Question 33.
Write SQL queries for the questions from (i) to (v) on the basis of table Class.
Table: Class [5]

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.


Name 5 major string functions with their purpose.
(i) SELECT * FROM Class WHERE Subject=‘Non-medical ‘:
(ii) SELECT * FROM Class ORDER BY Name;
(iii) SELECT * FROM Class WHERE Grade IN (‘B’, ‘C’);
(iv) INSERT INTO Class VALUES (06, ‘Jack’, 2800, ‘Humanities’, 98, ‘A’):
(v) No


  1. CHAR() This function returns the character valué of the given integer value according to the ASCII table. It ignores the NULL value, By default, CHAR() returns a binary string.
  2. CONCAT() This function can have one or more arguments and it returns a string that is the result of concatenating the arguments.
  3. SUBSTR() This function returns the substring (specified number of character) from a particular position of a given string.
  4. TRIM() This function is used to return a string after removing all prefix or suffix spaces from the given string. In other words, this function removes leading and trailing spaces from a given string.
  5. LENGTH() This function returns the length of the string in bytes. The length of the string also includes all the blanks.

Question 34.
Granuda consultants are setting up a secured network for their office campus at Faridabad for their day-to-day office and web based activities. They are planning to have connectivity between 3 buildings and the head office situated in Kolkata. [5]

Answer the questions (i) to (v) after going through the building positions in the campus and other details, which are given below.

Distance between various buildings

Building RAVI to Building JAMUNA 120 m
Building RAVI to Building GANGA 50 m
Building GANGA to Building JAMUNA 65 m
Faridabad Campus to Head Office 1460 km

Number of computers

Building RAVI 25
Building JAMUNA 150
Building GANGA 51
Head Office 10

(i) Suggest the most suitable place (i.e. Building) to house the server of this organisation. Also, give a reason to justify your suggested location.
(ii) Suggest a cable layout of connections between the building inside the campus.
(iii) Suggest the placement of the following devices with justification
(a) Switch
(b) Repeater
(iv) Consultancy is planning to connect its office in Faridabad which is more than 10 km from head office. Which type of network will be formed?
(v) State the use of HUB?
(i) The most suitable place to house, the server is JAMUNA because it has maximum number of computers.


(iii) (a) Switches are needed in every building to share bandwidth in every building.
(b) Repeaters may be skipped as per above layout, (because distance is less than 100 m) however, if building RAVI
and building JAMUNA are directly connected, we can place a repeater there as the distance between these two
buildings is more than 100 m.

(iv) MAN

(v) A hub is a device, used with computer systems to connect several computers together. It acts as a centralised
connection to several computers with the central node or server.

Question 35.
Given the following bar graph, write the Python code to display same as. [5]


Write the code to plot the below chart.


import pandas as pd
import matplotlib.pyplot as plt
data = (‘Country’ : [‘USA', ‘Canada’, ‘Germany’, ‘UK’, ‘France’],
‘GDP_Per_Capita’: [45000, 42000, 52000, 49000, 47000]
df = pd.DataFrame(data, columns=[’Country’,’GDP_Per_Capita’])
df.plot(x =‘Country’, y=’GDP_Per_Capita’, kind = ‘bar’)
plt. show( )


import pandas as pd
import matplotlib.pyplot as plt
data = {‘Year’: [1920, 1930, 1940, 1950, 1960, 1970, 1980, 1990, 2000, 2010], ‘Unemployment_Rate’: [9.8, 12, 8, 7.2, 6.9, 7, 6.5, 6.2, 5, 5, 6.3]
df = pd.DataFrame(data,coiumns=[’Year’,’Unemployment_Rate’])
df.plot(x =‘Year’, y=’Unemployment_Rate’, kind = ‘line’)

Show More

Related Articles

यौगिक किसे कहते हैं? परिभाषा, प्रकार और विशेषताएं | Yogik Kise Kahate Hain Circuit Breaker Kya Hai Ohm ka Niyam Power Factor Kya hai Basic Electrical in Hindi Interview Questions In Hindi