0% found this document useful (0 votes)
6 views

2022_may_python-programming2020-pattern

Uploaded by

kawdenamrata69
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views

2022_may_python-programming2020-pattern

Uploaded by

kawdenamrata69
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

.

\1 lYlcuch /Apr,'1 2o2L


TotalNo. of Questions : 5l
SEAT No. :
P6983 [Total No. of Pages
Is86sl I :
4
F.Y.M.C.A. s
IT2I OGRAMMIF{G LiBRARY
a ) (Semester - II)
Time:2% HoursJ *
fMax. Marks:
Instructions to the
1) Ail
2) Figures full marks.
3)A at one place.

i. ,t
QI) eqtrect option. (% mark each)
l,' t10l
io, '
I
, Whio:ii type of prograrnming does
PYlhon supp#t?
a) Object-orienredprograrnming
b) Structuredprogramming
c) Functional
d) all ofthe mentioned
iD Which keyword is in python language?
a) function ..,}, b) def
c) tun d) define
ii, Which of the following fun*ion is used to export graph generaf in 1,,.
*"'"'

matplotlib to-png file fonnat? '\'


4
L. a) savefig b) savefigure ""J
c) save d) export
rv) Which of the following method used for
a) display b)
c) execute d)
v) In python, a class is for ect.
a) a distraction b)
c) a nuisance d) ue print

P,TO.
d

LBRARY

I vi) You can delete properties of objects by using the keyrvord.


* a)
--
c)
vii) The can be accessed via?
a)
b) ClassN
c) doc
d)
viii) Which function can be used to check if a file 'Sample,txt'

S Path. is Exits ('sample.txt')


b exists ('sample.txt') {-\"j

c) IS file ('sample.txt') \
q#ot is File ('samPle.fxt')
ix) Which of following is NOT a c math module?
a) ampoft * from math import*
c) Import math as mt math import pi,sin
x) Which of follorving regular expression cache?
pos( )
re.Subn ( )
xi) mode?
b) Thread_sleep f\,'
d) Thread - sleep
xii) an exception hardling
a) try b) except
c) accept d) fiually
xiii) a collection

c) db. emp. deletemany ( ) d) db o


xiv) Chose the correct syntax of reshape is Numpy anay_.
a) affay. reshape(shape) b) affay)
c) reshape (away, shape) d) (shape)

- 2fi1 )
[s86sl
d

L}BRARY
,-o
xv) Tf zoo: ;'lion', 'tiger'], what willbe zaoxz? 1

a) ['lion','lion,''tiger," tiger,lJ. " *


b) ['lion']
c) ['tiger']
d) ['lion,"ti "tiger']
xvi) What is creating single valued tupie?

a) (a) b) (,)

c) d) {a}
xvii) literal denotated by triple quote for providing the
of certain program elements.
a) b) docstrng
c) d) :,...
interface ".'';
xviii) is used to -g--#ry module in python is

a) pip b)
c) py
xix) The character the start and end of strng,
respectively.
a) $and$ * ancl &
c) ^ and. ^and$
xx) The most inrportant in Numpy is an N-dimensional ar.,t:4y

type called?
I a) narry b) Ndany
c) ndrray d) NdAnay ( )

92) a) Write a program to check the number or odd.


Program should accept integer digits t3l
b) Illustrate types of arguments used in rvith example. I3l

c) Discuss the polymorphism concept create suitable python


classes.
*^ l4l
OR

3
ls86sl - zat
.f
s

LiB&ARY
'{ a) Write a python program for the following 13I
t i) Create list of fruits
ii) Add new fruit in list. #'^fn
iii) sort the list.
19 delete last nam list.
b) Write a the given number is even or odd.
Handle t3t
c) Explain in python r.vith example. l4l

Q3) a) Write a to create an employee. txt file and stor"e employee


S. tzl
b) program to create "employee" collection with fields"
address, phone email and dept) m m04go DB. Prform the
operations - "^.-l lsI
r) lay allemployees in "Accounts" departtnent
,!t
ii)l,,,1: '

iii) en'rployee rD -123


c) Wha
What is the difference plo? t3I

a) What is set? Explain with 13I


b) Write aprogramto employee details &om "Employee"
collection stored t3t
c) Write a program employee details stored in "Emp loyq"9-,
collection stored in database. -12r
d) Write python read "employee" . txt" file and display alffirate
employee record. i;'.: ,"):r'' l2l

Q4 a) Write a program for extracting emaii address .t4l


b) What is synchronization in threading? Explain t4l
c) What is module? Explain with example. tzt
OR
a) Write aprogram to validate URLusing Explain every
special character of the regular this program. l4l
b) Write a multithreading program, w prints square of a
number and another thread prints a number. Also display the
total time taken for the execu t4l
c) What is anonymous function with example. [21

ls86sl - 20t 4
d

LBRARY

QS) a) Create 5x5 2D numpy assay and retrieve top left


corner 2x2 aray from
1
*
i,,". .

I2l
b) Write a program to illustrate s"ilcrng rn nltmpy anay.
f. .

121
c) Create paundas ,,$jng two dimensional li s t. p erfbrm following
operations.
I4l
, Count
ii) ues in first column.
iii) n of columns in data frame
d) Exp w.r.t. oops in python.
121
D ii) Setf

I OR

a) Create 3x3 numpy array and


mean and median.[2]
b) Create a series frorn numpy
max and mean of unique
items of series.
c)
Izt
14l
ID Name DA
1001 Mohan 10000
1002 ,,1
\..
i
Sachin s000 9000
1003 Yirat 4000 8000
r)

D
L u)
d)
121

***

i.
._,;. "l
"\]
[s86sl - 201 5

You might also like