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

Xii - Cs Answer Key

This document is an answer key for the Pre-Board Exam in Computer Science for Class XII at Velammal Bodhi Campus, dated February 5, 2025. It includes answers to multiple choice questions, short answer questions, and programming tasks, totaling 70 marks. The document is structured into sections with varying point values for each question.

Uploaded by

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

Xii - Cs Answer Key

This document is an answer key for the Pre-Board Exam in Computer Science for Class XII at Velammal Bodhi Campus, dated February 5, 2025. It includes answers to multiple choice questions, short answer questions, and programming tasks, totaling 70 marks. The document is structured into sections with varying point values for each question.

Uploaded by

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

VELAMMMAL BODHI CAMPUS

“Velammal Knowledge Park”


PRE-BOARD EXAM – 2024-25
Class : XII ANSWER KEY Marks : 70
Date : 05.02.2025 COMPUTER SCIENCE Duration : 3 hours

I. ANSWER ALL THE QUESTIONS: (21x1=21)

1 True
2 b) -5
3 a) PEOR
4 b) [[10,10,10],4]
5 b) []
6 a) aho%a$Day1 20
7 False
8 All the best
cs
cs
cs
9 b) It removes the last pair in the dictionary and returns the pair as a tuple.
10 d) return number
11 c) 6$14$10$
12 a) The first matching except block encountered from top to bottom
13 print(file.tell())
14 like
15 a) When the Admission_Number is zer
16 a) avg(quantity)
17 b) Reset the price of the product to its 10% where the name of the product
starts with S.
18 circuit switching / (any relevant answer)
19 b) TELNET
20 (a) Both (A) and (R) are true and (R) is the correct explanation for (A).
21 (d) (A) is false but (R) is true.

SECTION – B (7x2=14)
22. i) Keywords are predefined and specific reserved words,which hold special meaning.An 2
identifier is a different term or name given to a variable.
ii) a) „\n‟ : string literal / literal
b) True : Boolean literal / Keyword
23. i) print(my_exam[::2]) 2
ii) a) L1.extend(L2) (OR)
b) L1.sort()
L2.sort()
24. A and D 2
Minimum : 0 , Maximum : 3
25. A) 945$9* 2
26. i) A) Degree – 4 , Cardinality – 6, Primary key - CDNO (OR) 2
B) NOT NULL constraint
ii) A) insert into library values(10009,”Motivational Songs”,15,70); (OR)
B) select min(QTY) from library;
27. Relevant point with examples.(Also show degree & cardinality) 2
28. Relevant point (one advantage & disadvantage) 2
SECTION – C (3x3=9)
29 S#I#T$ (OR) Xlcome@**o *F4*!* 3
30. A) 3
def push_str(S):
Vowel_String=[]
for i in S:
for j in i:
if j in „aeiouAEIOU‟:
Vowel_String.append(i)
break
return Vowel_String
s=[]
for i in range(6):
S.append(input(“enter string:”))
Vowel_String=push_str(S)

def pop_String():
if not Vowel_String:
print(“underflow”)
else:
print(Vowel_String.pop())
pop_String()

def Disp_String():
for i in range(len(Vowel_String)):
print(Vowel_String[-i-1],end=‟‟)
else:
print(“None”)
Disp_String()
(OR)
i) def push_Product(ProductStack, new_Product):
ProductStack.append(new_Product)
ii) def pop_Product(ProductStack):
if not ProductStack:
print(“underflow”)
else:
return (ProductStack.pop())
iii) def peep(ProductStack):
if not ProductStack:
print(“None”)
else:
print(ProductStack[-1])
31. A) 3
def display():
f=open(“Article.txt”)
max=0
for i in f.read().split():
if i==i[::-1]:
l=len(i)
if l>max:
max=l
k=i
print(k)
display()
(OR)
B) def display():
f=open(“Phone.txt”)
r=f.readlines()
for i in r:
j=i.split()
if j[1].startswith(„7‟):
print(i)
display()
SECTION – D (4x4=16)
32. i) import csv 4
def addPlayer(name, matches, goals):
f=open(“football.csv”,‟a‟,newline=‟‟)
w=csv.writer(f)
l=[name,matches,goals]
w.writerow(l)
f.close()
ii) def HighestAverage():
f=open(“football.csv”,‟r‟,newline=‟‟)
r=csv.reader(f)
x=‟‟
high_goal=0
next(r)
for i in r:
if int(i[1])!=0:
y=int(rec[2]) / int(rec[1])
if y> high_goal:
high_goal=y
x=rec[0]
print(“the player with the highset Average=”,x)
f.close()
33. A) 4
i) select sum(salary) from employee where project is not NULL;
ii) select count(*) from employee group by project;
iii) select distinct project from employee;
iv) select name from employee where DOB>”1992-10-31”;
(OR)
B)
i) Name Project
Satyansh NULL
Ranjan P01
Muneera P01
Alex P02
Akhtar P04
ii)
Name Salary
Ranjan 150000
Akhtar 125000
Name DOB DOJ
iii) Ranjan 1990-07-12 2015-01-21
Akhtar 1992-06-21 2015-02-01
Muneera 1996-11-15 2018-08-19

min(DOJ) max(DOB)
iv)
2015-01-21 1996-11-15
34. import mysql.connector as m 4
def runs_scored(run):
mycon=m.connector (host=”localhost”,user=”shanaiya”,
password=”happy”,database=”sports”)
cur=mycon.cursor()
cur.execute(“select*from cricket where runs>{}order by pname desc:”.format(run))
data=cur.fetchall()
print(data)
mycon.close()
run=int(input(“enter the runs:”))
run_scored(run)
35 a) delete from transact where amount < 1000; 4
b) select ttype , sum(amount) from transact group by ttype; (OR)
select ttype ,sum(amount) from transact where ttype in ("debit","credit") group by ttype;
(OR) (any relevant SQL command)
c) select name,amount from customer,transact where
customer.cno=transact.cno and ttype=”credit”;
d) update customer set phone =9988117700 where cno=1002;
SECTION – E ( 2x5=10)
36. i) import pickle 5
def accept():
f=open(“Election.bin”,”ab”)
l=[]
for i in range(5):
pid=int(input(“enter id:”))
pname=input(“enter party name:”)
cname=input(“enter candidate name:”)
vote=int(input(“enter total vote:”))
l=[pid,pname,cname,vote]
pickle.dump(l,f)
f.close()
ii) def search(PartyName):
f=open(“Election.bin”,”rb”)
found=0
while True:
try:
l=pickle.load(f)
if l[1]==PartyName:
print(l)
except EOFError:
break
f.close()
if found==0:
print(“no such party name exist”)
iii) def update():
f=open(“Election.bin”,”rb+”)
pid=int(input(“enter partyid to be updated:”))
while True:
try:
l=pickle.load(f)
if l[0]==pid:
l[2]=input(“enter new candidate to be updated:”)
l[3]=int(input(“enter new total votes:”))
pickle.dump(l,f)
print(i)
except EOFError:
break
f.close()
37. a) Repeater 5
b) City Head office Village 1 Tranning center

Village 2 Tranning center Village 3 Tranning center

c) hub/switch
d) VOIP
e) MAN

*********
ALL THE BEST

You might also like