Docsity

Informatics Practices: Exploring Series Objects in Python, Schemes and Mind Maps of English

Toggle sidebar
bg1
SUMMER BREAK HOLIDAY HOMEWORK
CLASS: XII D
SUBJECT: INFORMATICS PRACTICES
Q1. Write a code to create a series object:
a. using the Python sequence [4, 6, 8, 10]
b. using the Python sequence [11, 21, 31, 41 ]
c. using individual characters ‘o’, ‘h’ and ‘o’.
d. using a string “So funny”
e. using 3 different words: “I”, “am”, “laughing”
f. using an ndarray that has 5 elements in the range 24 to 64
g. using an ndarray that is created by tiling a list [3, 5], twice.
h. using a dictionary that stores the number of students in each section of class 12 in your
school.
i. That stores the initial budget allocated (50000/- each) for the four Qts of the year: Q1, Q2, Q3
and Q4.
Q2. A python list namely ‘section’ stores names (‘A’,’B’,’C’,’D’) of class 12 in your school. Another list
‘contri’ stores the contribution made by these students to a charity fund endorsed by the school.
Write code to create a Series object that stores the contribution amount as the values and the section
names as the indexes.
Q3. Sequences ‘section’ and ‘contri’ stores the section names (‘A’,’B’,’C’,’D’,’E’) and the contribution
made by them respectively (6700, 5600, 5000, 5200,nil) for a charity. Your school has decided to
donate as much contribution as made by each section i.e. the donation will be doubled. Write code to
create a Series object that stores the contribution amount as the values and the section names as the
indexes with datatype as float32.
Q4. Consider a Series object S1 that stores the number of students in each section of class 12:
A 39
B 41
C 42
D 44
First two sections have been given a task of selling tickets @100/- per ticket as part of a social
experiment. Write code to display how much they have collected.
Q5. Consider a Series object S1 that stores the contribution of each section of class 12:
A 6700
B 5600
C 5000
D 5200
Write code to modify the amount of sections ‘A’ as 7600 and for sections ‘C’ and ‘D’ as 7000. Print
changed object.
Q6. Number of students in classes 11 & 12 in 3 streams (‘Sci’, Com’,’Hum’) are stored in two series
objects C11 & C12. Write code to find total number of studenst in classes 11 & 12, stream wise.
Q7. Series object S1 that stores the contribution of each section of class 12:
A 6700
B 5600
C 5000
D 5200
Write a program to display which sections made a contribution more than Rs. 5500/-
pf2

Partial preview of the text

Download Informatics Practices: Exploring Series Objects in Python and more Schemes and Mind Maps English in PDF only on Docsity!

SUMMER BREAK HOLIDAY HOMEWORK

CLASS: XII D

SUBJECT: INFORMATICS PRACTICES

Q1. Write a code to create a series object: a. using the Python sequence [4, 6, 8, 10] b. using the Python sequence [11, 21, 31, 41 ] c. using individual characters ‘o’, ‘h’ and ‘o’. d. using a string “So funny” e. using 3 different words: “I”, “am”, “laughing” f. using an ndarray that has 5 elements in the range 24 to 64 g. using an ndarray that is created by tiling a list [3, 5], twice. h. using a dictionary that stores the number of students in each section of class 12 in your school. i. That stores the initial budget allocated (50000/- each) for the four Qts of the year: Q1, Q2, Q and Q4. Q2. A python list namely ‘section’ stores names (‘A’,’B’,’C’,’D’) of class 12 in your school. Another list ‘contri’ stores the contribution made by these students to a charity fund endorsed by the school. Write code to create a Series object that stores the contribution amount as the values and the section names as the indexes. Q3. Sequences ‘section’ and ‘contri’ stores the section names (‘A’,’B’,’C’,’D’,’E’) and the contribution made by them respectively (6700, 5600, 5000, 5200,nil) for a charity. Your school has decided to donate as much contribution as made by each section i.e. the donation will be doubled. Write code to create a Series object that stores the contribution amount as the values and the section names as the indexes with datatype as float32. Q4. Consider a Series object S1 that stores the number of students in each section of class 12: A 39 B 41 C 42 D 44 First two sections have been given a task of selling tickets @100/- per ticket as part of a social experiment. Write code to display how much they have collected. Q5. Consider a Series object S1 that stores the contribution of each section of class 12: A 6700 B 5600 C 5000 D 5200 Write code to modify the amount of sections ‘A’ as 7600 and for sections ‘C’ and ‘D’ as 7000. Print changed object. Q6. Number of students in classes 11 & 12 in 3 streams (‘Sci’, Com’,’Hum’) are stored in two series objects C11 & C12. Write code to find total number of studenst in classes 11 & 12, stream wise. Q7. Series object S1 that stores the contribution of each section of class 12: A 6700 B 5600 C 5000 D 5200 Write a program to display which sections made a contribution more than Rs. 5500/-