0% found this document useful (0 votes)
161 views3 pages

Class 12 (IP) PT. 01 Answer Key2024-25

Uploaded by

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

Class 12 (IP) PT. 01 Answer Key2024-25

Uploaded by

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

TAKSHILA SCHOOL, AHMEDNAGAR

PT.1 EXAMINATION (2024-25)


CLASS: XII
SUBJECT: INFORMATICS PRACTICES MAX. MARKS: 70
TIME: 3 HOURS
General Instructions: -
1. This question paper contains five sections, Section A to E.
2. All questions are compulsory.
3. Section A have 08 questions carrying 01 mark each.
4. Section B has 07 Very Short Answer type questions carrying 02 marks each.
5. Section C has 03 Short Answer type questions carrying 03 marks each.
6. Section D has 02 Long Answer type questions carrying 05 marks each.
7. Section E has 01 questions carrying 02 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.
Q.NO. QUESTION MARKS
PART A
1 Ans:-d.ndim (1)
2 Ans:- b. iterrows() (1)
3 Ans:- b.S[2] (1)
4 Ans:- c. nbyte (1)
5 Ans:- c.join() (1)
6 Ans:- b. Columns (1)
7 Ans:- b. transpose (1)
8 Ans:- c. nbyte (1)
PART-B
9 df['val'] = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10] (2)
10 0 6 (2)
1 6
2 6
3 6
4 6
dtype:int32
11 Ans:- (2)
import pandas as pd
capitals = ['New Delhi', 'London', 'Copenhagen', 'Bangkok']
countries = ['India', 'UK', 'Denmark', 'Thailand']
country = pd.Series(capitals, index=countries)
print(country)
12 Ans:- (2)

In Pandas,
The describe() is used to view some basic statistical details.
The info() function is used to print a summary of a DataFrame. This method show
information about a DataFrame.
13 Ans:- (2)
pivot_table() :- It does not raise errors for multiple entries of a row, column
combination.
pivot() :- It raise errors for multiple entries of a row, column combination.
14 Ans:- (2)
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)
15 Ans:- (2)
65 II1
75 III
85 IV
dtype: object
PART-C
16 Ans:- (3)

(a)

>>> sales[['Item', 'Revenue']]


(b)

>>> sales.iloc[2:7]
(c)

>>> sales.Item[4]
17 Ans:- (3)

(a) wdf.min()
(b) wdf.max(axis=1)
(c) wdf.Rainfall.var()
(d) wdf.tail(10).mean() , wdf.tail(10).mode() , wdf.tail(10).median()
PART-D
18 Import pandas as pd (5)
Import numpy as np
Nmk=mk.fillna({‘A’:20,’B’:10,’C’:30,’D’:0})
Print(nmk)
19 Ans:- (5)
import pandas as pd
import numpy as np
result = pd.DataFrame( { "rollno" : [11, 7, 6, 1, 10, 7,
11], \
"marks" : [11, 12, 13, 14, 15, 16, 17] } )

stu = pd.DataFrame( { "Name" : [ "Name1", "Name2", "Name3",


"Name4", \
"Name6", "Name7",
"Name8" ],"Subject" : [16, 25, 21, 15, 18, 14, 10], \
"class" : [11, 12, 13, 14, 15, 16, 17] }
)
print( result.join(stu) )
20 Answer = (2)
(a)
A B C
0 15 17 NaN
1 16 18 NaN
2 20 21 NaN
(b)
ERROR
(c)
A B C
0 15 17 12
1 16 18 15
2 20 21 27

You might also like