11th SC UT 3 Python 2023-24
11th SC UT 3 Python 2023-24
UNIT TEST – 3
COMPUTER SCIENCE WITH PYTHON
TIME : 1:30 HOURS CLASS XI MAXIMUM MARKS 40
Q.16- How are Lists are different from the Strings when both are sequences? 3Mark
Q.17- What is the difference between append() and extend() function? 2Mark
Q.18- If a is [1, 2, 3] 4Mark
a) what is the difference (if any) between a * 3 and [a, a, a]?
b) is a * 3 equivalent to a + a + a?
c) what is the meaning of a[1:1] = 9?
d) what's the difference between a[1:2] = 4 and a[1:1] = 4?
Q.19- What does each of the following expressions evaluate to? Suppose that L is the list
["These", ["are", "a", "few", "words"], "that", "we", "will", "use"]. 4Mark
1. L[1][0::2]
2. "a" in L[1][0]
3. L[:1] + L[1]
4. L[2][2] in L[1]
Q.20- Write a Python program to search for an element in a given list of numbers. 4Mark
Q.21- Write a Python Program to count the frequency of a given element in a list of numbers. 4Mark
Q.22- write a Python program to calculate the mean of a given list of numbers. 4Mark