KEMBAR78
Class 12 Computer Science Sample Paper Set 1 | PDF | Parameter (Computer Programming) | Computing
0% found this document useful (0 votes)
1K views13 pages

Class 12 Computer Science Sample Paper Set 1

The Class 12 Computer Science Sample Paper is a meticulously crafted resource aimed at helping students prepare for their board examinations. It includes a diverse set of questions, such as programming problems, theoretical concepts, and case studies, aligned with the latest CBSE syllabus and exam pattern. Covering essential topics like Python programming, data structures, database management, and computer networks, this sample paper enhances both conceptual understanding and practical skills.

Uploaded by

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

Class 12 Computer Science Sample Paper Set 1

The Class 12 Computer Science Sample Paper is a meticulously crafted resource aimed at helping students prepare for their board examinations. It includes a diverse set of questions, such as programming problems, theoretical concepts, and case studies, aligned with the latest CBSE syllabus and exam pattern. Covering essential topics like Python programming, data structures, database management, and computer networks, this sample paper enhances both conceptual understanding and practical skills.

Uploaded by

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

Dear Teachers and Students,

Join School of Educators' exclusive WhatsApp, Telegram, and Signal groups for FREE access
to a vast range of educational resources designed to help you achieve 100/100 in exams!
Separate groups for teachers and students are available, packed with valuable content to
boost your performance.

Additionally, benefit from expert tips, practical advice, and study hacks designed to enhance
performance in both CBSE exams and competitive entrance tests.

Don’t miss out—join today and take the first step toward academic excellence!

Join the Teachers and Students


Group by Clicking the Link Below
Series ARSP/01 Set ~ 1
Roll No. Q.P Code 15/1/1
Candidates must write the Q.P Code
on the title page of the answer-book.

 Please check that this question paper contains 09 printed pages.


 Q.P. Code given on the right hand side of the question paper should be written
on the title page of the answer-book by the candidate.
 Please check that this question paper contains 37 questions.
 Please write down the serial number of the question in the answer-book
before attempting it.
 15 Minute times has been allotted to read this question paper. The question
paper will be distributed at 10:15 a.m. From 10.15 a.m to 10.30 a.m, the students
will read the question paper only and will not write any answer on the answer –
book during this period.

COMPUTER SCIENCE

Time allowed: 3 hours Maximum Marks: 70


General Instructions:

​This question paper contains 37 questions.

All questions are compulsory. However, internal choices have been provided in some questions. Attempt only one
of the choices in such questions.

The paper is divided into 5 Sections- A, B, C, D and E.

Section A consists of 21 questions (1 to 21). Each question carries 1 Mark.

Section B consists of 7 questions (22 to 28). Each question carries 2 Marks.

Section C consists of 3 questions (29 to 31). Each question carries 3 Marks.

Section D consists of 4 questions (32 to 35). Each question carries 4 Marks.

Section E consists of 2 questions (36 to 37). Each question carries 5 Marks.

All programming questions are to be answered using Python Language only.

In case of MCQ, text of the correct answer should also be written.

Section A
1. State true or false: [1]
There is no conceptual limit to the size of a list.
2. Fill in the blank: [1]
________ is used for point-to-point communication or unicast communication such as radar and satellite.

a) RADIOWAVES b) BLUETOOTH

c) MICROWAVES d) INFRARED WAVES


3. What is the best way to represent attributes in a large database? [1]

a) All of these b) Concatenation

c) Dot Representation d) Relational-and


4. What is the mean of L in LEGB rule for scope resolution? [1]

a) Local b) Library

c) Least d) Last
5. Out of the following, find those identifiers, which cannot be used for naming Variables or Functions in a Python [1]
program:
Price*Qty, class, For, do, 4thCol, totally, Row31, _Amount
6. What is the full form of CSMA/CA? [1]
a) Collision Sense Multiple Access/Collision b) Carrier Sense Multiple Access/Collision
Act Avoidance

c) Carrier Sense Multiple Access/Collision Act d) Collision Sense Multiple Access/Collision


Avoidance
7. Information stored on a storage device with a specific name is called a ________. [1]

a) array b) file

c) file pointer d) tuple


8. The SQL statements to access and manipulate data in existing table is/are: [1]

a) System Control Statements b) Session Control Statements

c) DDL d) DML
9. Aggregate functions are also known as [1]

a) group functions b) Add function

c) group method d) sum function


10. What is following code doing? [1]
file = open("contacts.txt", "a")
name = input ("Please enter name.")
phno = input ("Please enter phone number.")
file.write(name + ','+ phno + "\n")
file.close()
11. State true or false: [1]
In Python, a variable is a placeholder for data.
12. When a stack is empty and an element's deletion is tried from the stack, it is called an ________. [1]

a) UNDERFLOW b) OVERFLOW

c) NOFLOW d) EXTRAFLOW
13. Write a query to display the Sum, Average, Highest and Lowest salary of the employees grouped by department [1]
number and sub-grouped by the job.
14. Internet is an example of ________ topology. [1]

a) Mesh b) Star

c) Tree d) Bus
15. What is the output of the following code? [1]

t = (10, 20, 30, 40, 50, 60, 70)


pnint(t[5:-1])

a) (10, 20, 30, 40, 50, 60, 70) b) Blank output()

c) (10, 20, 30, 40, 50) d) (10, 30, 50, 70)


16. Fill in the blank. [1]
________ function is used to arrange the elements of a list in ascending order.
a) ascending () b) sort ()

c) asort () d) arrange ()
17. Traditionally, Internet checksum is [1]

a) 24-bit b) 16-bit

c) 32-bit d) 8-bit
18. Which of the following wireless transmission media is best suited for MAN? [1]

a) Radio Link b) Microwave

c) Infrared d) Bluetooth
19. Assertion (A): The list can contain data of different types. [1]
Reason (R): We can use slice [:] operator to access the data of the list.

a) Both A and R are true and R is the correct b) Both A and R are true but R is not the
explanation of A. correct explanation of A.

c) A is true but R is false. d) A is false but R is true.


20. Assertion (A): The Python write excel file is used to perform multiple operations on a spreadsheet using the [1]
xlwt module.
Reason (R): xlwt module can also be used to write text, numbers, and formulas to multiple worksheets.

a) Both A and R are true and R is the correct b) Both A and R are true but R is not the
explanation of A. correct explanation of A.

c) A is true but R is false. d) A is false but R is true.


21. Assertion (A): A parameter is a value listed inside the parentheses in the function definition. [1]
Reason (R): An argument is a value that is sent to the function when it is called.

a) Both A and R are true and R is the correct b) Both A and R are true but R is not the
explanation of A. correct explanation of A.

c) A is true but R is false. d) A is false but R is true.


Section B
22. What is demodulation? How is it different from modulation? [2]
23. List the most common parameters and the usage that are passed to communicate with the database. [2]
24. Determine the hierarchy of operations and evaluate following expression. [2]

A = 3*4//5 + 5//7 + 8 - 2 + 4//2

OR
If you are asked to label the Python loops as determinable or non-determinable, which label would you give to which
loop? Justify your answer.
25. Consider the following table structure [2]
Table: Faculty with fields as

F_ID (P)

Fname

Lname
Hire_date

Salary

Write the Python code to create the above table.


26. What are immutable and mutable types? List immutable and mutable types of Python. [2]
OR
Write a program that takes any two lists L and M of the same size and adds their elements together to form a new list
N whose elements are sums of the corresponding elements in L and M. For instance, if L = [3, 1, 4] and M = [1, 5, 9],
then N should equal [4, 6, 13].
27. Differentiate between text file and CSV file. [2]
OR
Identify the error in the following code:
1. import pickle
2. data = ['one', 2, [3, 4, 5]]
3. with open('data2.dat', 'rb') as f:
4. pickle.dump(data, f)
28. How can you make a module helloworld out of these two functions? [2]
def helIo():
print 'Hello,',
def world():
print 'World!'
Section C
29. What is the utility of: [3]
i. default arguments
ii. keyword arguments
OR
What is the significance of having functions in a program?
30. In a table Apply, there is a column namely Experience that can store only one of these values: 'Fresher', [3]
'Private-sector-experience', 'Public-sector-experience', 'Govt.-sector experience'. You want to sort the data of
table based on column experience as per this order: 'Govt-sector-experience', 'Public-sector-experience',
'Private-sector-experience', 'Fresher'. Write an SQL query to achieve this.
OR
Write the disadvantages of SQL.
31. Write the definition of a function ChangeGender() in Python, which reads the contents of a text file [3]
"BIOPIC.TXT" and displays the content of the file with every occurrence of the word 'he' replaced by 'she'.
For example, if the
content of the file "BIOPIC.TXT" is as follows:
Last time he went to Agra,
there was too much crowd, which he did not like.
So this time he decided to visit some hill station.
The function should read the file content and display the output as follows:
Last time she went to Agra,
there was too much crowd, which she did not like.
So this time she decided to visit some hill station.
OR
What do you understand by the local and global scope of variables? How can you access a global variable inside the
function, if the function has a variable with the same name?
Section D
32. Write Addnew(Book) and Remove(Book) methods in Python to Add a new Book and Remove a Book from a [4]
List of Books, considering them to act as PUSH and POP operations of the data structure stack.
OR
Write a program to print a string in reverse order.
33. For the text file nanthem.txt shown below, write a program to find the most commonly occurring word. Also, list [4]
the frequencies of words in the text file.
Jan gan man adhinayaka jaya he
Bharat bhagya vidhata
Panjab sindh Gujarat Maratha
Dravid Utkal banga
Vindhye Himachal Yamuna Ganga
Uchchal jaladhi tarang
Tava shubh name jage,
Tava shubh ashish mange,
Gahe tava jaya gatha.
Jan gan mangal dayak jaya he
34. Write SQL commands for (i) to (v) on the basis of table EMPLOYEE [4]
TABLE: EMPLOYEE

S NO NAME BASIC DEPARTMENT DATO FAPP AGE SEX

1 KARAN 8000 PERSONNEL 27/03/97 35 M

2 DIVAKAR 9500 COMPUTER 20/01/98 34 M

3 DIVYA 7300 ACCOUNTS 19/02/97 34 F

4 ARUN 8350 PERSONNEL 01/01/95 33 M

5 SABINA 9500 ACCOUNTS 12/01/96 36 F

6 JOHN 7400 FINANCE 24/02/97 36 M

7 ROBERT 8250 PERSONNEL 20/02/97 39 M

8 RUBINA 9450 MAINTENANCE 22/02/98 37 F

9 VIKAS 7500 COMPUTER 13/01/94 41 M

10 MOHAN 9300 MAINTENANCE 19/02/98 37 M

i. Which command will be used to list the names of the employees, who are more than 34 years old sorted by
NAME.
a. SELECT NAME FROM EMPLOYEE WHERE AGE>34 ORDER BY NAME;
b. SELECT * FROM EMPLOYEE WHERE AGE>34 ORDER BY NAME;
c. SELECT NAME FROM EMPLOYEE WHERE AGE>34;
d. SELECT NAME FROM EMPLOYEE AGE>34 ORDER BY NAME;
ii. Write a query to display a report, listing NAME, BASIC, DEPARTMENT and annual salary. Annual salary
equals to BASIC * 12.
iii. Insert the following data in the EMPLOYEE table
11, 'VIJAY', 9300, 'FINANCE', '13/7/98', 35, "M"
iv. Write a query to count the number of employees, who are either working in PERSONNEL or COMPUTER
department.
v. Write the degree and cardinality of the table EMPLOYEE.
OR
Consider the following tables GAMES and PLAYER and answer (b) and (c) parts of this question:
Table: GAMES

GCode Game Name Type Number Prize Money Schedule Date

101 Carom Board Indoor 2 5000 23-Jan-2004

102 Badminton Outdoor 2 12000 12-Dec-2003

103 Table Tennis Indoor 4 8000 14-Feb-2004

105 Chess Indoor 2 9000 01-Jan-2004

108 Lawn Tennis Outdoor 4 25000 19-Mar-2004

Table: PLAYER

PCode Name GCode

1 Nabi Ahmad 101

2 Ravi Sahai 108

3 Jatin 101

4 Nazneen 103

a. What do you understand by primary key and candidate keys?


b. Write SQL commands for the following statements:
i. To display the name of all GAMES with their GCodes.
ii. To display details of those GAMES which are having PrizeMoney more than 7000.
iii. To display the content of the GAMES table in ascending order of Schedule Date.
iv. To display sum of PrizeMoney for each type of GAMES.
c. Give the output of the following SQL queries:
i. SELECT COUNT (DISTINCT Number) FROM GAMES;
ii. SELECT MAX(ScheduleDate), MIN (ScheduleDate) FROM GAMES;
iii. SELECT Name, GameName FROM GAMES G, PLAYER P WHERE (G.Gcode= P.Gcode AND
G.PrizeMoney>10000);
iv. SELECT DISTINCT Gcode FROM PLAYER;
35. Create following table using Python code. [4]
Table Name = Customer
Database - xyzcorp.
Userid - Adminxyz
Password - Axydm12

CUSTNUMB CUSTNAME ADDRESS BALANCE CREDLIM SLSRNUMB

481 Tilak lane, CP,


124 TINA ADAMS 41800.75 50,000 3
Delhi

215 Mylapore,
256 R VENKAT 100000.75 80,000 6
Chennai

808, Bala Nagar,


567 BHUVNA BALAJI 57,000.75 50000 6
Hyderabad

149, Plot 182, sec-9


622 PRATHAM JAIN 57500.75 80,000 12
Dwarka, Delhi

Section E
36. G.R.K International Inc. is planning to connect its Bengaluru Office Setup with its Head Office in Delhi. The [5]
Bengaluru Office G.R.K. International Inc. is spread across an area of approx. 1 square kilometres consisting of
3 blocks. Human Resources, Academics and Administration. You as a network expert have to suggest answers to
the four queries (i) to (v) raised by them.
Note Keep the distances between blocks and number of computers in each block in mind, while providing them
the solutions.

Shortest distances between various blocks

Human Resources to Administration 100 m

Human Resources to Academics 65 m

Academics to Administration 110 m

Delhi Head Office to Bengaluru Office Setup 2350 km

Number of computers installed at various blocks

Block Number of Computers

Human Resources 156

Administration 20

Academics 100

Delhi Head Office 20

i. Suggest the most suitable block in the Bengaluru Office Setup to host the server. Give a suitable reason with
your suggestion.
ii. Suggest the cable layout among the various blocks within the Bengaluru Office Setup for connecting the
blocks.
iii. Suggest a suitable networking device to be installed in each of the blocks essentially required for connecting
computers inside the blocks with fast and efficient connectivity.
iv. Suggest the most suitable media to provide secure, fast and reliable data connectivity between Delhi Head
Office and the Bengaluru Office Setup.
v. Expand the following
WAN
LAN
37. Write SQL queries for (i) to (iv) and find outputs for SQL queries (v) to (viii), which are based on the tables: [5]
DVD

DCODE DTITLE DTYPE

F101 Henry Martin Folk

Cl 02 Dhrupad Classical

C101 The Planets Classical

F102 Universal Soldier Folk

R102 A day in the life Rock

MEMBER

MID NAME DCODE ISSUEDATE

101 AGAM SINGH R102 2017-11-30

103 ARTH JOSEPH F102 2016-12-13

102 NISHA HANS C101 2017-07-24

i. To display all details from the table MEMBER in descending order of ISSUEDATE.
ii. To display the DCODE and DTITLE of all Folk Type DVDs from the table DVD.
iii. To display the Dtype and number of DVDs in each DTYPE from the table DVD.
iv. To display all NAME and ISSUEDATE of those members from the table MEMBER who have DVDs issued
(i.e., ISSUEDATE) in the year 2017.
v. SELECT MIN (ISSUEDATE) FROM MEMBER;
vi. SELECT DISTINCT DTYPE FROM DVD;
vii. SELECT D.DCODE. NAME, DTITLE: FROM DVD D, MEMBER M WHERE D.DCODE=M.DCODE;
viii. SELECT DTITLE FROM DVD WHERE DTYPE NOT IN ("Folk", "Classical");
OR
Give output for following SQL queries as per given table(s):
Table: HOSPITAL

No. Name Age Department Dateofadm Charges Sex

1. Arpit 62 Surgery 21/01/98 300 M

2. Zarina 22 ENT 12/12/97 250 F


3. Kareem 32 Orthopedic 19/02/98 200 M

4. Arun 12 Surgery 11/01/98 300 M

5. Zubin 30 ENT 12/01/98 250 M

6. Ketaki 16 ENT 24/02/98 250 F

7. Ankita 29 Cardiology 20/2/98 800 F

8. Zareen 45 Gynecology 22/02/98 300 F

9. Kush 19 Cardiology 13/01/98 800 M

10. Shilpa 23 Nuclear Medicine 21/02/98 400 F

i. SELECT COUNT (DISTINCT Charges) FROM HOSPITAL;


ii. SELECT MIN (Age) FROM HOSPITAL WHERE Sex = "F";
iii. SELECT SUM (Charges) FROM HOSPITAL WHERE Department = "ENT";
iv. SELECT AVG (Charges) FROM HOSPITAL WHERE Dateofadm< {12/08/98};

You might also like