0% found this document useful (0 votes)
57 views4 pages

Army Public School Shillong Annual Examination - 2022 - 23 Subject: Informatics Practices Class XI Time: 3 Hrs. Max. Marks: 70

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)
57 views4 pages

Army Public School Shillong Annual Examination - 2022 - 23 Subject: Informatics Practices Class XI Time: 3 Hrs. Max. Marks: 70

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/ 4

ARMY PUBLIC SCHOOL SHILLONG

ANNUAL EXAMINATION – 2022 - 23


Subject: Informatics Practices Class XI

Time: 3 Hrs. Max. Marks: 70

(i). All the Questions are compulsory.


(ii). Number written at the right margin indicates the Marks.
(iii). Give appropriate syntax and examples wherever necessary.
(iv). There are questions where you have to show the output of the program and show the
evaluation process as a part of answer.
(v). Any assumption regarding table, command, text etc. are allowed.
(vi). Ensure that there is no overwriting in the program, query.
(vii). Question no 2 has option to answer any 5 out of 6.
(viii). Question no 3 has option to answer any 4 out of 5.
(ix). Question no 5 is MCQ where you have to attempt only 10 questions out of 13.

1. Answer the following question in short. 1 X 10 = 10


a) Define a loop of a program?
b) Which character(s) is/are used as NOT operator in a python program?
c) Code A Q=5
Code B Q += 2
What actually the line Code B of the above code is doing in the given snippet?
d) SELECT name from STU where MARK > 90;
Rectify the mistake if any in the above code and re-write the correct SQL statement (Assume
that STU tables has created with corresponding columns).
e) A graphical representation of solving a problem in any computer programming language is
known as __________.
f) What will be the value of C after executing the following python code.
B = 56
C =A // 3

g) Name any two attribute which can used with ALTER command in MySQL.
h)
D = (1:2, 3:4, 5:6)

What is wrong in the above code of Python dictionary? Rectify the mistake and re-write the
corrected expression.
i) Python dictionary is immutable. TRUE/FALSE .
j) Which command is used to display the structure of a table in MySQL?

- Page No. 1 of 4 -
2 Answer any five questions from the following program snippets of python. 2 X 5 = 10
a) Refer the following python code and predict the output.

str_val=“HELLO”
L1=list(str_value)
print(L1)

b) What will be the output from the following code.


L1 =[5,2,3,7,1]
for a in L1:
print(i)

c) What will be the value of L1 after executing the following code.


L1=[2,3,7,1]
L2=[0,9,3]
L1.append(L2)
print(L1)

d) What will be the value of D1 after executing the following Dictionary code.
D1 = {'Mohan':95, 'Ram':89, 'Suhel':92, 'Sangeeta':85}
for key in D1:
print(key,':',D1[key])

e) What will be the value of D1 after executing the following Dictionary code.
D1 = {'Mohan':95, 'Ram':89, 'Suhel':92, 'Sangeeta':85}
D1['Meena'] = 78
print(D1)

f) What will be the value of D after executing the following Dictionary code.
D = {'M':95, 'R':89, 'S':92}
D1 = {‘A':25, ‘K':35}
D.update(D1)
print(D)

3. Answer any four from the following. 3 X 4 = 12


a) Consider the following given python dictionary and predict the output of the code given in
Python w.r.t. the given dictionary.
R = {'Mohan': 95, 'Ram': 89, 'Suhel': 92, 'Sangeeta': 85, 'Meena': 78}
i) print(R.get('Ram'))
ii) print(R.keys( ))
iii) print(R.values( ))

- Page No. 2 of 4 -
b) Consider the following MySQL table name as EMP and write the query to perform the task.

i) to display all the details who has “a” as the last letter of the ADDRESS.
ii) to display NAME, FATHER of those whose EMP_CODE between is 202 and 204.
iii) to remove all the data of ‘Rahul’.

c) Define a Primary key. Write the syntax to create the EMP table given in Q3(b) with
EMP_CODE as primary key. And write the query to insert at least a row.
d) Differentiate between the Relational Data Model and Heirarchical Data Model. Explain with
examples.
e). Write the rules for nomenclature of a variable.
4. Consider the following table and write the query for (i) to (vi) and output for (vii) to (x). 1 X 10 = 10
Table name : MARKET
ADM_NO CATEGORY FATHER STU_NAME SALARY PHONE VEHICLE
APS101 JCO Jason Rameshor 50000 1234567 Yes
APS 105 ORs Rishab Das Asween 60000 7956411 No
APS 103 Civil Proloy Nath Anil Kasya 70000 1024668 Yes
APS 102 Staff Kukrejha Thomson 80000 5787999 Yes
APS 104 Teacher Sunita Alexendir 90000 3547899 No
APS 108 MTS Pintu Anita 20000 7897888 No
APS 109 LDC Sany Santosh 30000 8968888 No
APS 111 JCO Ammy Anthony 25000 7878787 Yes

i). to insert all the values using appropriate command. (write only one in the answer script)
ii). change the data type of attribute “ SALARY “ to varchar with size 20.
iii). to replace the category “ Civil ” by “ General ”.
iv). to display all those Father whose STU_NAME has “ x “ as the fourth letter.
v). display all the Admission no. in descending order of the Name who work as JCO.
vi). to increase the SALARY of all by increasing 10% of the existing SALARY.

vii). select ADM_NO from MARKET where SALARY between 50000 and 80000;
viii). alter table MARKET drop VEHICLE ;
ix). update MARKET set ADM_NO= ‘ ‘ where STU_NAME like ‘_ _ _ _ e%’;
x). select CATEGORY, FATHER from MARKET order by SALARY desc;

- Page No. 3 of 4 -
5. Choose the correct option of any ten questions from the following. 1 X 10 = 10
a) What will be the order of the data being sorted after the execution of given SQL query?
SELECT * From School Order by Class;
(a) Order of inserting records in a table (b) Ascending order
(c) Descending order (d) None of these
b) Which clause in SQL is used to apply a condition in a transaction of SQL?
(a) As (b) Having (c) Where (d) On
c) Identify the valid variable name from the following literals
a) P Q b) P$Q c) P+Q d) PQ
d) _____ constraint is used to check duplicity of values in MySQL tables and discard if repeated.
(a) Unique (b) Remove (c) Distinct (d) All
e) Which of the following commands will change row(s) of the table from MySQL database?
(a) REPLACE TABLE (b) CHANGE TABLE (c) UPDATE (d) ALTER TABLE
f) DML stands for ____________________.

g) “Keywords can be used as identifiers/variables in Python programming language.”


(a) True (b) False (c) Sometimes based on condition (d) None of the above
h) Which statement consists of a logical operator?
(a) a + b ** c (b) a > b: (c) a and b not c (d) 2 in a
i) len( ) is used to input the values to be used in the dictionary program. True/False
j) Type casting is used between dissimilar _______ .
a) datatypes b) variables c) constant d) conditions
k) The meaning of a==5 in python script is:
a) The constant value a is stored/assigned in variable 5
b) The constant value 5 is stored/assigned in variable a
c) a is equal to 5 d) None of the above
l) Consider the lists below and select the correct statement
L1 = [1,2,3]
L2 = [1,[2,3]]
a) L1= =L2 b) L1 Not equal L2 c) L1< > L2 d) L1!=L2
m) Consider the lists below and select the correct statement
L1 = [1,2,3,7,9]
L2 = [1,2,5,8]
L1< L2
a) True b) False c) Error in the condition d) None of the above
6. a) WAP in python to a) add two list elements b) to delete an element. 2+2=4
b) WAP in python to a) remove an element from a dictionary using POP function
b) clear the entire elements of dictionary using clear function. 2+2=4
c) WAP in python to search an element in an user inputted list (Linear search). 5
d) WAP to find the largest element number in a list using sorting method. 5

- Page No. 4 of 4 -

You might also like