0% found this document useful (0 votes)
73 views7 pages

Sample Paper 1 7

Uploaded by

hemant_sangeeta
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)
73 views7 pages

Sample Paper 1 7

Uploaded by

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

General Instructions:

1.This question paper contains two parts A and B. Each part is compulsory.
2.Both part A and part B have choices.
3. Part-A has 2 sections:

a.Section-I is short answer questions, to be answered in one word or one line.


b.Section-II has two case studies questions. Each case study has 4 case-based
sub-
parts. An examinee is to attempt any 4 out of the 5 subparts.
4. Part-B is descriptive paper.

5.Part-B has three sections:


a.Section-I is short answer questions of 2 marks each in which two questions
have internal options.
b.Section-II is long answer questions of 3 marks each in which two questions
have internal options.
c. Section-III is very long answer questions of 5 marks each in which one
question have internal options.
Part-A
Section-I
Attempt any 15 questions from questions 1 to 21 each question carry one mark.
1 The device that can operate in place of hub is a: 1
2 What is used to represent missing data in pandas object? 1
3 Which one is not DDL command? 1
a.alter b.delete c.drop d.create
4 Which type of transmission media is the least expensive to manufacture? 1
a.Coaxial b.Twisted pair c.CAT6 d.fibre optics
5 Which function is used to draw horizontal bar chart? 1
6 Using someone else’s twitter handle to post something, will be termed as: 1
a.fraud b.identity theft c.online stealing d.violation
7 Mr.Aakash is setting LAN connection in his office but in long distance he is getting 1
weak and corrupted signal, he wants to regenerates and amplifies the signal. Help
him by suggesting suitable network device.
8 Can you use = comparison operator to compare Null values in a select query? 1
9 State whether true or false: 1
i.Series can store elements of different data types.
ii.The keys of a dictionary must be of immutable types.
10 An attribute in a relation is a foreign key if it is the key in any other relation. 1
11 Abbreviate: i)VoIP ii)HTTP 1
12 The information/art/work that exits in digital form is called 1
13 To get top 5 rows of dataframe, you may use function. 1
a.head b.head(5) c.top() d.top(5)
14 In SQL, which keyword is used to select only one copy of each set of duplicable 1
rows?
15 Write name of an open source DBMS. 1
16 Which library need to import to use arange() method in your program? 1
17 Mr.Naveen is using query “Select * from manager;” but he is getting error, no 1
database
is selected, Help him to select database “emp” from already existing databases.
18 Discarded electrical or electronic devices are known as 1
19 Seema thinks firewall is used to protect from fire, but Sudhir told her firewall is used 1
to secure a private network from a public network. Whether Sudhir is giving correct
definition of firewall or not?
20 Which function brings you vertical subsets from a dataframe in the form of column 1
index and a series object containing values for all rows in that column.
21 I can keep you signed in. 1
I can remember your site preferences.
I can give you locally relevant content. Who am I?
Section-II
Both the case study based questions(22 & 23) are compulsory. Attempt any four
sub parts from each question. Each sub question carries 1 mark.
22 Consider the following tables ACTIVITY and COACH. Write SQL commands for
the following statements:
Acod ActivityNam Stadiu Table:ACTIVITY
ParticipantsNu PrizeMone ScheduleDat
e e m m y e
1001 Relay 100 x 4 Star 16 10000 23-Jan-04
Annex
1002 High jump Star 10 12000 12-Dec-03
Annex
1003 Shot put Super 12 8000 14-Feb-04
power
1005 Long jump Star 12 9000 01-Jan-04
Annex
1008 Discuss Super 10 15000 19-Mar-04
throw power

Table:COACH
Pcode Name Acode
1 Ahmed Hussain 1001
2 Ravinder 1008
3 Janila 1001
4 Naaz 1003
(i) To display the names of all activities with their Acodes in descending order. 1
(ii) To display sum of PrizeMoney for the Activities played in each of the Stadium 1
separately.
(iii) To display the coach’s names and Acodes in ascending order of Acode from the table 1
COACH.
(iv) To display the content of all activities for which ScheduleDate is earlier than 01-01- 1
2004 in ascending order of ParticipantsNum.
(v) Which column in Table:COACH is treated as Foreign key. 1
23 Consider the following DataFrame df and answer any four questions from (i)- (v)

Rollno name UT1 UT2 UT3 UT4


1 Prerna Singh 24 24 20 22
2 Manish Arora 18 17 19 22
3 Tanish Goel 20 22 18 24
4 Falguni Jain 22 20 24 20
5 Kanika Bhatnagar 15 20 18 22
6 Ramandeep Kaur 20 15 22 24
(i) Write down the command that will give output: 1
rollno 6
name Tanish Goel
UT1 24
UT2 24
UT3 24
UT4 48
a. print(df.max)
b. print(df.max())
c. print(df.max(axis=1))
d. print(df.max, axis=1)
(ii) The teacher needs to know the marks scored by the student with roll number 1
4. Help her to identify the correct set of statement/s from the given options :

a. df1=df[df[‘rollno’]==4]
print(df1)

b. df1=df[rollno==4]
print(df1)
c. df1=df[df.rollno=4]
print(df1)
d. df1=df[df.rollno==4]
print(df1)
(iii) 1
Which of the following statement/s will give the exact number of values in
each column of the dataframe?
i. print(df.count())
ii. print(df.count(0))
iii. print(df.count)
iv. print(df.count(axis=’index’))
Choose the correct option:
a. both (i) and (ii)
b. only (ii)
c. (i), (ii) and (iii)
d. (i), (ii) and (iv)
(iv) Which of the following command will display the column labels of the 1

DataFrame?
a. print(df.columns())
b. print(df.column())
c. print(df.column)
d. print(df.columns)
(v) Ms. Sharma, the class teacher wants to add a new column, the scores of Grade 1
with the values, ‘ A’, ‘B’, ‘A’, ‘A’, ‘B’, ‘A’
choose the command to do so:

a. df.column=[’A’,’B’,’A’,’A’,’B’,’A’]
b. df [‘Grade’]=[’A’,’B’,’A’,’A’,’B’,’A’]
c. df.loc[‘Grade’]= [’A’,’B’,’A’,’A’,’B’,’A’]
d. Both (b) and (c) are correct
Part-B
Section-I
This contain short answer questions of 2 marks each in which two questions
have internal options.

24 Given are two objects, a list object namely lst1 and a series object namely ser1, both 2
are having similar values i.e., 2,4,6,8. Find out the output produced by following
statements:
i)print(lst1*2) ii)print(ser1*2)
OR
Consider the below given two code fragments. Will they produce the same output?
Why/why not?
i)fst=[9,10,11] ii)fst=pd.Series(data=[9,10,11])
ob1=pd.Series(data=fst*2) ob2=pd.Series(data=fst*2)
print(ob1) print(ob2)
25 Give difference between char and varchar. 2
OR
Sivani is working in MySQL.Differentiate her between the Where and having
clause
26 As a citizen of india, what advise you should give to others for e-waste disposal? 2
27 Write command to create given table. 2
Columne Type SIZE Constraint Description

Empid INTEGER 6 PRIMARY employee NUMBER


KEY
Dno int 3 Department no
Name VARCHAR 20 NAME OF DEPARTMENT
Salary float (8,2) LOCATION OF DEPARTMENT
Gender char 1 Gender ‘m’ for male ‘f’ for female
Job char 30 Type of job
28 In binary addition, if a column in a data frame contains a NaN and the corresponding 2
column in other DataFrame is a numeric value, then what would be returned as a
result? Why?
29 Rina is using a table emp. She wants to display highest sal obtained in each job. She 2
wrote the following query
select job , max(sal) from emp;
but she did not get the desired result. Rewrite the above query with necessary
changes to get desired output.
30 Write the expanded name of the following: 2
a.HTTP b.OSS c.URL d.FLOSS
31 What is the purpose of using router? 2
32 Why is following code not producing any result? Why is it giving errors? 2
a=range(10,50,12)
b=range(90,200,20)
matplotlib.pyplot.plot(a,b)
33 Consider the decimal number x with value 8459.2654. Write commands in SQL to: 2
i. round it off to a whole number
ii. round it to 2 places before the decimal.
Section-II 3
This contain long answer questions of 3 marks each in which two questions have
internal options.

34 Describe measures to recycle your e-waste safely. 3


OR
What is privacy laws? Explain IT ACT 2000 for privacy.
35 Given a DataFrame mdf as shown below: 3
A B C
0 1 2 3
1 4 5 6
Find out the errors in following statements:
i)mdf.drop([“total”,”order”],axis=1)
ii) mdf.drop([‘A’,’D’])
iii) mdf.drop([‘A’,’D’],axis=1)
OR
Consider two objects x and y. x is a list whereas y is a Series. Both have values 20,
40,90, 110.
What will be the output of the following two statements considering that above
objects have been created already
a. print (x*2) b. print(y*2)
Justify your answer.
36 Define: a. Primary key b.Candidate key c.Foreign key 3
37 Create an array A, in the range 1 to 20 with values 1.25 apart. Another array B,
contains the log values of the elements in the array A.
Write a program to create a scatter plot of first vs second array with red circle
markers, specify the x-axis title as ‘Random values’ and y-axis title as ‘logarithm
values’.
Section-III 5
This contain very long answer questions of 5 marks each in which one question
have internal option.

38 5
drinkcode dname price calories
101 lime and lemon 20.00 120
102 apple drink 18.00 120
103 nature nectar 15.00 115
104 green mango 15.00 140
105 aam panna 20.00 135
106 mango juice 12.00 150
v)To add column quantity data type int size 3.
OR
i) Write query to concat drinkcode and dname as drinkcodename having price
of Rs.20 of above table.
ii) Display drink name of above table in capital letters.
iii) Write query to remove leading spaces of string ‘ kendriya’.
iv) Display the position of occurance of string ‘OL’ in string
“rollnoinschool”. v)Display institute code “uss” from string “uss/23/67/09”.

39 Consider the following DataFrame df. 5


Fruits Pulses Rice Wheat
Andhra p. 7830 931.0 7452.4 NaN
Gujarat 11950 818.0 1930.0 2737.0
Kerala 113.1 1.7 2604.8 NaN
Punjab 7152 33. 11586.2 16440.5
Tripura 44.1 23.2 814.6 0.5
Uttar p. 140169.2 2184.4 13754.0 30056.0
Write a script that does the following:
a. Lists the presence of missing data in whole dataframe.
b. Fills the missing values with 999.
c.Print the dataframe after filling missing value.
40 Software development company has set up its new center at Raipur for its office and 5
web based activities. It has 4 blocks of buildings named block A, block B, block C
and block D.
Number of Computes

Block A 25
Block B 50
Block C 125
Block D 10
Shortest distances between various blocks in meters:
Block A to Block 60m
B
Block B to Block 40m
C
Block C to Block 30m
A
Block D to Block 50m
C
(i) Draw layout for given setup.
(ii) Suggest the most suitable place to house the server with suitable reason.
(iii)The company is planning to link all the blocks through a secure and high speed
wired medium. Suggest a way to connect all the blocks.
(iv)Suggest the type of network to connect all the blocks with suitable reason.
(v)Company wants to protect their connection from outside network suggest
hardware/software for given purpose.

You might also like