0% found this document useful (0 votes)
43 views5 pages

CS-PB-MS Set-1

Uploaded by

h7627432
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)
43 views5 pages

CS-PB-MS Set-1

Uploaded by

h7627432
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/ 5

KENDRIYA VIDYALAYA SANGATHAN: JABALPUR REGION

PREBOARD-1 (2024-25)
COMPUTER SCIENCE (THEORY)
CLASS: XII Time allowed: 3 Hours Maximum Marks:70
Marking Scheme
General Instructions:
● In case any doubt regarding the answer the evaluator can check by himself/herself and do the
needful

Q No. Section-A (21x1=21Marks) Marks


1. False (1)
2. (A)C) not (True or False) (1)
3. (B)B) split() (1)
4. (A)C) error (1)
5. B) xlnd (1)
6. D) 2024 (1)
7. B) print(D['Computer']) (1)
8. B) remove deletes the list or tuple from the memory (1)
9. A) 1 (1)
10. B) 100, 10 (1)
11. try …except block (1)
12. A) 945$9* (1)
13. A) DDL (1)
14. B) Show tuples of students table only with the age values 17,19,21 (1)
15. A) date (1)
16. D) upper (1)
17. D) MIME (1)
18. D) Repeater (1)
19. B) Subscriber Identity Module & General Packet Radio Service (1)
20. B) Both A and R are true and R is not the correct explanation for A (1)
21. A) Both A and R are true and R is the correct explanation for A (1)
Q No Section-B(7x2=14 Marks) Marks
22. a) Either definition of dictionary or example of dictionary 1 mark
b) (i) x=10 integer ½ mark (ii) x=10,20 tuple ½ mark
23. Relevant explanation about in operator 1 mark
Eg.
A=”welcome” 1 mark
if ‘e’ in A: example
print(“found a vowel”)
or any code that demonstrate the use of in operator
24. Consider T=(10,20,30) and L=[60,50,40] answer the question I and II
(I)
L.append(T) 1 mark
OR OR
As T is tuple deletion of an element is tuple is not possible due to 1 mark
its immutable nature.(any relevant correct reason)
(II)
L.insert(50,2) 1 mark
OR OR
del T 1 mark

Page:1/5
25.
B) m$p$ C) c$n$ For each correct answer ½ mark

Value of b minimum 1 and maximum 14


½ mark for each minimum and maximum
26. Any relevant code with following marks distribution
½ mark for correct function declaration
1 ½ mark for logic (2)

import pickle
def RECORDS():
with open(“district.dat”,”r”) as file:
name=input(“Enter name of district”)
try:
while(1):
a=pickle.load(file)
if a[0]==name:
print(a)
except EOFError:
break
or any relevant correct code
27. (I)
A) Use of Primary key or Any relevant correct answer 1 mark
OR
B) Use of Primary key for rno in students table and use of foreign key in marks
table for connecting the two tables or Any relevant correct answer 1mark

(II)
A) Alter table stationary modify(price number(10,2); 1 mark (2)
OR
B) Update table stationary set price=Null;
28. A) Any 2 correct difference between star and mesh topology - 2 marks
(partial marks can be awarded on partial correct answer). (2)
OR
B) (i) VoLTE Voice over Long Term Evolution 1 mark
(ii) GSM Global System for Mobile communication 1 mark
Q No. Section-C(3x3=9Marks) Marks
29. 1 ½ mark for logic, ½ mark for indentation ½ mark for correct file opening
command , ½ mark for print command
(3)
A) with open( “chars.txt”,”r”) as file:
d=file.read()
WL=d.split()
for w in WL:
if w[0]==’c’ or w[0]==’C’:
print(w)
or any other correct relevant code
OR
A) with open( “info.txt”,”r”) as file:
d=file.read()
for x in d:
if x.isdigit():
print(x)
or any other correct relevant code
Page:2/5
30. 1 ½ mark for logic, ½ mark for indentation ½ mark for variable declaration,
½ mark for print command
A)
Inventory=[]
def New_In(Inventory,newdata):
Inventory.append(newdata)

def Del_In(Inventory):
if len(Inventory)==0:
print(“Nothing to POP”) (3)
else:
Inventory.pop()

def Show_In(Inventory):
for p in range(len(Inventory)-1,-1,-1):
print(Inventory[p])

code=input(“Code”)
name=input(“Name”)
price=input(“Price)
L=[code,name,price]
New_In(Inverntory, L)
Del_In(Inventory)
Show_In(Inventory)

Or any other correct relevant code

OR
B)
N=””
Consonants=[]
def Push(x):
for p in x:
if p not in [‘a’,’A’,’e’,’E’, ‘i’,’I’,’o’,’O’, ‘u’,’U’] :
N=p
Consonants.append(N)
def Display():
for p in range(len(Inventory)-1,-1,-1):
print(Consonants[p])
Push(“Welcome to stacks”)
Display()

Or any other correct relevant code.


31. {'p': 1, 'r': 2, 'o': 1, 'g': 1, 'a': 1, 'm': 1, 's': 1} 3 marks
(partial marking may be given)
OR
erreer 3 marks (3)
(partial marking may be given)
Q No. Section-D( 4x4=16Marks) Marks
32. A) Write the queries for the following:
i) Select sum(qsold) from wsale where qtr=3;
ii) Select * from watches order by qty desc;
iii) Select sum(qty) from watches;
iv) Select wname, max(qsold) from watches , wsale where
Page:3/5
watches.id=wsale.wid and qtr=1;
iv) OR
B) Write the output
i) Sum(price) (4)
6290
ii)
Id Wname Price Type Qty
W01 High Time 1200 Common 75
W02 Life line 1600 Gents 150
W03 Wave 780 Common 240

iii) sum(qty) type


315 Common
610 Gents
250 Ladies

iv)
Wname Price Qtr
High Time 1200 1
Wave 780 3
33. ½ mark correct import statement
½ mark for opening file in correct mode
½ mark for making reader object
½ mark for print statement (4)
2 mark for logic
import csv
def READ():
with open(“candidates.csv”, “r”) as csv_file:
reading=csv.reader(csv_file)
for x in reading:
if x[2]>75 :
print(x)
def IDENTIFY():
count=0
with open(“candidates.csv”, “r”) as csv_file:
reading=csv.reader(csv_file)
for x in reading:
if x[2]<=75 :
count=count+1
print(“number of records less then 75% “ ,count)

or any other correct relevant code


34. (I)Select * from departments where date_join < ’01-01-2010’; 1
(II) Select d_name, d_incharge from departments where d_incharge like ‘%m 1
%;’
(III) Update departments set grant=grant+1200 where d_no in (‘D99’, ‘D23’) 1
(IV) d_name grant
Primary Null
OR
sum(grant) 1
34000

Page:4/5
35. import mysql_connector 1 mark
connect=mysql.connector.connect(hostname=”localhost”, user=”root”, for
password=”root”, database=”db”) connect
cur=connect.cursor() ion
string
def Add_Vehicle():
Model = input(“Enter model”) ½
Make_year= input(“Enter year”) mark
Qty= input(“Enter qty”) for
Price =input(“Enter price”) variable
Q=”insert into Vehicle values(‘” + Model +”’,” + Make_year + “,” + Qty declarat
+”,” + Price +”)” ion
cur.execute(Q)
connect.commit()
½ mark
def Search_vehicle(): for
model=input(“Enter model to search”) correct
Q=”select * from Vehicle where Model=’” + model+ ’” function
cur.execute(Q) declarati
for x in cur: on
print(x)
2 marks
for logic
Q.No. SECTIONE(2X5=10 Marks) Marks
36. (I) Create table staff ( ID int(4) primary key, Name char(30), Designation (2)
char(10) , Birth_date date, Salary numeric(10,2));
(II) Select * from staff where designation= ‘Sales Executive’ ; (1)
(III) Update staff set designation =’Assistant’ where salary between 15000 and (1)
17000;
(IV) Select sum(*) from staff where name like “%j”; (1)
37. i) Development building with relevant and correct explanation 1
ii) Switch 1
iii) Any correct relevant layout with same placement of the building 1
iv) Correct & Relevant answer as per the layout given .by the student 1
v) A) Video conferencing
OR 1
B) LAN

Page:5/5

You might also like