Section A
Question. The size of a dataframe is
(a) mutable, always
(b) immutable
(c) mutable , if it is created using a dictionary
(d) mutable , if it is created using a list
Answer
A
Question. The function that returns the number of elements in a Series is
(a) length()
(b) count()
(c) number()
(d) len()
Answer
D
Question. The method that plots multiple line charts in one plot for comparison of data is
(a) multiplot()
(b) subPlot()
(c) subplot()
(d) None of these
Answer
C
Question. A dataframe can have
(a) 1 axis
(b) 2 axis
(c) 3 axis
(d) more than 3 axis
Answer
B
Question. Given a Series created from a List , Lstlang=[‘C++’,‘Python’,‘Java’,‘Ruby’],as follows :
import pandas as pd
Langseries=pd.Series(Lstlang)
What will be output of following code?
print(Langseries[- 1])
(a) [Ruby]
(b) [Java]
(c) KeyError
(d) [Ruby , Java]
Answer
C
Question. Given a code :
Numseries = pd.Series ([12,14,16])
print(Numseries*2)
Find the output.
(a) [24,28,32]
(b) Error
(c) [12,14,16, 12,14,16]
(d) None of these
Answer
A
Question. To arrange the data of a dataframe in descending order, the parameter to be added is
(a) ascending=True
(b) ascending=False
(c) Ascending=false
(d) ascending=false
Answer
B
Question. The contents of one dataframe can be added at the end of another by using the …….. function.
(a) add()
(b) append()
(c) end()
(d) None of these
Answer
B
Question. The function that removes a row from a dataframe temporarily is
(a) del( )
(b) pop()
(c) drop()
(d) delete()
Answer
C
Question. The constant NaN belongs to the ……….. module.
(a) pyplot
(b) numpy
(c) matplotlib
(d) pandas
Answer
B
Question. Which of the following is against the etiquette while communicating in a network?
(a) Asking age
(b) Sending huge file attachments
(c) Asking gender
(d) All of these
Answer
D
Question. Which of the following is a proprietary software?
(a) MS-Windows
(b) MS-Office
(c) Both (a) and
(b) (d) Python
Answer
C
Question. Which of the following is/are the benefit(s) of e-Waste management?
(a) Saving the environment
(b) Creating jobs
(c) Recovery of precious metals
(d) All of these
Answer
D
Question. The keys of a dictionary are
(a) mutable types
(b) immutable types
(c) can be mutable or immutable
(d) None of these
Answer
B
Question. The different types of digital footprints are
(a) active footprints
(b) passive footprints
(c) Both (a) and (b)
(d) confidential footprints
Answer
C
Question. The digital footprints are
(a) traceable for unlimited period
(b) not traceable
(c) traceable for a limited period
(d) None of these
Answer
A
Question. Given statements to create a Series as follows. Which of the statement is correct?
(Assuming pandas is imported as p)
(a) int = p.Series([1,2,3,4])
(b) 12= p.Series([12,14,16,18])
(c) s1= p.series([1,2,3])
(d) s1= p.Series([1,2,3])
Answer
D
Question. Proprietary softwares are
(a) can be copied for free
(b) cannot be copied for free
(c) can be copied for limited number of users for free
(d) None of the above
Answer
B
Question. It must to specify the delimiter while using the to_csv() function.
(a) Yes
(b) No
(c) Not always required
(d) There is no delimiter parameter
Answer
B
Question. Cookies are
(a) temporary internet files
(b) viruses
(c) trojans
(d) antivirus softwares
Answer
A
Question. Categories of e-Wastes consist of
(a) precious metals
(b) hazardous materials
(c) Both (a) and (b)
(d) Neither (a) nor (b)
Answer
C
Question. Which one of the following is a netiquette?
(a) Cyber bullying
(b) Sending offensive mails
(c) Respecting others privacy
(d) Asking gender
Answer
C
Question. In Python, the mode that allows to write multiple lines of code and execute together is
(a) script mode
(b) interactive mode
(c) compile mode
(d) interpret mode
Answer
A
Question. A comment in a pandas code is written using
(a) ^
(b) &
(c) !
(d) #
Answer
D
Question. A panel has ……….. dimensions.
(a) 1
(b) 2
(c) >2
(d) 0
Answer
C
Section B
Question.Given a Series numSeries created as:
numSeries=pd.Series([11,12,13],index=[‘a’,’b’,’c’])
a 11
b 12
c 13
print(numSeries**2) will display
(a) a 121
b 144
(b) a 22
b 24
c 169 c 26
(c) ** operation is not possible on Series
(d) a 11 11
b 12 12
c 13 13
Answer
A
Question. Consider the following dataframe as:
Index Name Eco IP Eng
0 Ria 56 90 58
1 Priya 67 87 78
2 Jack 89 45 32
To delete the marks of ‘Eco’ subject from dataframe df is
(a) del df [Eco]
(b) del [Eco]
(c) del [‘Eco’]
(d) del df [‘Eco’]
Answer
D
Question. Rahul created a list storing the following
Lstbirds=[‘Parrot’,’Pigeon’,’Dove’]
Now, he wants to create a series that will store the prices 200,100 and 50 respectively as
the indexes of the series, the statement that will do this using a pandas alias “p” will be
(a) P.Series(Lstbirds,index=[200,100,50])
(b) p.series(Lstbirds,index=[200,100,50])
(c) p.Series(Lstbirds,index=[200,100,50])
(d) Any of (a), (b) or (c)
Answer
C
Question. The least harmful malware among the following is
(a) virus
(b) trojan
(c) worm
(d) adware
Answer
D
Question.

What kind of plot is this?
(a) Horizontal bar
(b) Bar
(c) Line
(d) Histogram
Answer
B
Question. Statement A Charts can be saved using savefig() function.
Statement B Only bar charts can be saved.
(a) Statement A is correct.
(b) Statement B is correct.
(c) Statement A is correct, but Statement B is incorrect.
(d) Statement A is incorrect, but Statement B is correct.
Answer
C
Question. To create a plot like the below figure, the parameter to be used with hist() function is

(a) histtype=‘frequency’
(b) histtype=‘outline‘
(c) histtype=‘step’
(d) histtype=‘outer‘
Answer
C
Question. Online posting of rumours, giving threats online, posting the victim’s personal information, comments aimed to publicly ridicule a victim is termed as ………… .
(a) hacking
(b) phishing
(c) cracking
(d) bullying
Answer
D
Question. Consider the statements regarding cookies:
Statement A They are created in remote servers.
Statement B They are created in local system.
Statement C They are temporary files.
Statement D They are created in intermediate systems.
(a) Statement A and Statement B
(b) Statement B and Statement C
(c) Statement C and Statement D
(d) Statement B and Statement D
Answer
C
Question. What is the output of following code?
Stud1={‘UT1’:[5,6,8],‘UT2’:[7,8,9]}
Stud2={‘UT1’:[3,3,6],‘UT2’:[5,9,8]}
Ds1=p.DataFrame(Stud1)
Ds2=p.DataFrame(Stud2)
print(Ds1.sub(Ds2))

Answer
C
Question. Softwares that are modifiable are called
(a) free softwares
(b) open source softwares
(c) proprietary softwares
(d) sharewares
Answer
B
Question. The function that adds a row to a dataframe is
(a) loc()
(b) add()
(c) iloc()
(d) None of these
Answer
A
Question. Which of the following are one of the stages of e-Waste management?
(a) Segregation
(b) Dismantling
(c) Recycling
(d) All of these
Answer
D
Question. The head() and tail() function differ by
(a) head() returns beginning rows but tail() returns middle rows
(b) head() returns beginning rows but tail() returns rows from anywhere
(c) tail() returns trailing rows but there is no function like head()
(d) head() returns beginning rows but tail() returns trailing rows
Answer
D
Question. Given the code:
Emp=[[‘Ram’,5,10,12,14],[‘Shyam’,6,7,8,18],[‘Sita’,7,18,19,20]]
Empdf=p.DataFrame(Emp,columns=[‘Sales2000’,‘Sales2010’,‘Sales2015’,‘Sales2020’,
‘Sales2020’])
del Empdf[‘Sales2010’] # Line1
Which statement is correct?
(a) The code will remove the column temporarily.
(b) The code will remove the column ‘Sales2010’ permanently.
(c) The code will produce an error.
(d) The ‘columns’ parameter is incorrect.
Answer
B
Question. Paromita was informed about the E-mail Id and password of her classmate Priya , by her another friend who is characteristically unethical. What is ethically correct for Paromita to do?
(a) Inform Priya to change her password.
(b) Give the password of Priya’s E-mail Id to all other classmates.
(c) Use Priya’s password to access her account.
(d) Flash her password publicly.
Answer
A
Question. The head(n) function displays
(a) only first n values
(b) only first n indexes and values
(c) only n indexes and values from middle
(d) head() function does not exist for series
Answer
B
Question. Given the Series:
ageseries=pd.Series([22,19,73,4])
print(ageseries>50)
The print statement will display

Answer
D
Question. Amit wants to create a dataframe whose columns store following data about his friends:
RollNo Name Email
1 Kailash kai@gmail.com
2 Rima rim@gmail.com
3 Sunil sun@gmail.com
Help him to create the dataframe:
(a) import pandas as pd
d={‘RollNo’:[1,2,3],‘Name’:[‘Kailash’,‘Rima’,‘Sunil’],‘Email’:[‘kai@gmail.com’,‘rim@gmail.com’,‘sun@gmail.com’]}
frienddf=pd.DataFrame(d)
(b) import pandas as p
d={‘RollNo’:[1,2,3],‘Name’:[‘Kailash’,‘Rima’,‘Sunil’],‘Email’:
[‘kai@gmail.com’,‘rim@gmail.com’,‘sun@gmail.com’]}
frienddf=pd.dataFrame(d)
(c) import pandas as pd
d={‘RollNo’:[1,2,3],‘Name’:[‘Kailash’,‘Rima’,‘Sunil’],‘Email’:[‘kai@gmail.com’,‘rim@gmail.com’,‘sun@gmail.com’]}
frienddf=pd.Dataframe(d)
(d) None of the above
Answer
A
Question. Publishing a software developed by others in our own name is an act of
(a) hacking
(b) phishing
(c) bullying
(d) copyright infringement
Answer
D
Question. Given a dataframe Traindf:
Index Trainno Tname Fare
0 12378 Padatik 8900
1 12344 Rajdhani 2900
2 12450 Gitanjali 5600
The command that displays output as 9 is
(a) Traindf.shape
(b) Traindf.size
(c) Traindf.length
(d) Traindf.len
Answer
B
Question. Given the series Library:
‘P’ Programming
‘F’ Fiction
‘H’ Horror
‘A’ Animals
The output of print(Library[2:4]) returns
(a) ‘H’ Horror
‘A’ Animals
(b) ‘H’ Horror
(c) ‘A’ Animals
(d) Error
Answer
A
Question. Given a dataframe “Patdf” carrying the following data of patients:
Index Pid Pname Dept Charges
0 1 Steffi Ortho 2000
1 2 Neel Paed 1500
2 3 Jack ENT 3000
The output of print(Patdf.loc[2,”Charges”]%2) returns
(a) 1
(b) 3000
(c) 2
(d) 0
Answer
D
Question. Consider the statements regarding attributes:
Statement A The rows attribute of a dataframe displays the number of rows.
Statement B The columns attribute of a dataframe displays the number of columns.
(a) Both statements are correct.
(b) Both statements are incorrect.
(c) Statement A is correct, Statement B is incorrect.
(d) Statement A is incorrect, Statement B is correct.
Answer
B
Section C
Case Study Based Questions)
This section consists of 6 questions (50 to 55). Attempt any 5 questions.Jacqueline has created the following dataframe consisting of data of houses of a school and the number of boys in the houses, shown as follows. She wants to perform certain operation on the data set. Help her with the correct actions.
House
Index Housename Location Boys
0 Ganga East 20
1 Yamuna West 30
2 Saraswati North 56
Question. She wants to add a column “Girls” storing the number of girls as [45,56,78], the statement would be
(a) House[] = [45,56,78]
(b) House[“Girls”] = [45,56,78]
(c) House[“Girls”] = {45,56,78}
(d) House[“Girls”] = 45,56,78
Answer
B
Question. She wants to see the number of columns . Which among the following will display the number of columns?
(a) len(House.columns)
(b) Len(House)
(c) Len(columns)
(d) Count(columns)
Answer
A
Question. She wants to display the second row only , the command she should write is
(a) House.iloc[1:2]
(b) House[2]
(c) House(1)
(d) None of these
Answer
A
Question. print(House.shape)
What will be the output of above code? (Note The ‘‘Girls’’ column is added to the dataframe)
(a) (3,3)
(b) (3,4)
(c) (2,4)
(d) (2,1)
Answer
B
Question. She wants the ‘‘Housename’’ column to be the index of the dataframe. The statement she should write is
(a) House.setindex(‘Housename’)
(b) House.setindex(‘name’)
(c) House.set_index(‘Housename’)
(d) House.resetindex(‘Housename’)
Answer
C
Question.55. She wrote the statement :
House.pop(“Girls”)
print(House)
What will be the output?

Answer
A