Half Yearly Sample Paper Class 12 Computer Science Set 2 2022-23
Time: 1:30 Hours/ Maximum marks:50
I. Choose the correct answer. 10
1. The smallest section of code that are used to perform particular task is called
a) Subroutines
b) Files
c) Modules
d) Pseudo code
2. A sequence of immutable objects are called
a) Built-in
b) List
c) Tuple
d) Selectors
3) Which members are accessible from outside the class?
a) private
b) public
c) protected
d) secured
4) Two main measures for the efficiency of an algorithm are
a) Processor and Memory
b) Complexity and capacity
c) Time and Space
d) Data and Processor
5. In which year python Language was released?
a) 1990
b) 1991
c) 2001
d) 2009
6. Who developed Python?
a) Narwick
b) Pascal
c) Charles Babbagbe
d) Guido Van Rossum
7. What plays a vital role in python programming?
a) Statements
b) Control!
c) Structure
d) Indentation
8) Which Statement is called Null Statement?
a) continue
b) break
c) Pass
d) goto
9. How many types of function?
a) 4
b) 3
c) 2
d) 6
10. Pick odd one in connection with collection data type
a) List
b) Tuple
c) Dictionary
d) Loop
PART-B
Answer any five questions. Question no. 16 is Compulsory. 5×2=10
11. What is recursive function?
12. What is scope?
13. What are the different modes that can be used to test python program?
14. What are the keywords to achieve jump statement?
15. Define Global Scope
16. Give the Syntax for user defined function
17. Write a note on break
PART-C
Answer any five questions. Question no. 21 is Compulsory. 5×3=15
18. Differentiate Pure and Impure function?
19. List the characteristics of an algorithm?
20. Explain Ternary operator with an example?
21. Write a python program to check the given number odd/even?
22. Write the rules of local variable?
23. Write key features of python
24. What are the advantages of tuples over a list.
PART-D
Answer any three questions. 3×5=15
25. Explain with an example interface and implementation?
Or
What is a list? Why list can be called as pairs, with suitable example.
26. Write LEGB Rule with example?
OR
What is Tokens and its types explain brifly.
27. Write a detail note on if….else statement with suitable example
OR
Explain the following built in function.
a) id()
c. type()
d.chr()
e.pow()