Python 3

Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

No. of Printed Pages : 4 180853/170853 c) any no.

argument and only one expression


Roll No. .................. d) one argument and any no. of expression
Q.6 The following is not the standard module-math
Comp. Engg.
function. (CO6)
Subject:- Comp. Prog. Using. Python
a) math.sqrt() b) math.log()
Time : 3Hrs. M.M. : 100 c) math.pow () d) math.datetime()
SECTION-A Q.7 Which of the following is not a common exception in
Note: Multiple choice questions. All questions are Python. (CO7)
compulsory (10x1=10) a) zero division error b) indentation error
Q.1 Python Programming Language is developed by c) name error d) Syntax error
__________ (CO1) Q.8 Which function is used to open a file in Python?
a) Guido Van Rossum b) Wick Van Rossum (CO8)
c) Niene Stom d) Richard a) file () b) new()
Q.2 Which of the following is not a string method in c) open() d) none of the above
Python? (CO2) Q.9 ______is an real world entity that has state and
a) Lower() b) upper () behavior. (CO9)
c) Capitilize () d) void main () a) class b) object
Q.3 Which of the following is a decision making c) method d) constructor
statement in Python? (CO3) Q.10 Which module in Python supports regular
a) for b) if-else-statement expression ? (CO10)
c) while d) do-while a) re b) regx
Q.4 How to access a value in List? (CO5) c) Pyregx d) none of above
a) mylist () b) mylist[] SECTION-B
c) mylist {} d) none Note: Objective type questions. All questions are
Q.5 Lambda function can have_______ (CO5) compulsory. (10x1=10)
a) any no. of argument and any no. of expression Q.11 IDLE stands for_________ (CO1)
b) one argument and one expression Q.12 *is a _______string operator. (CO2)

(1) 180853/170853 (2) 180853/170853


Q.13 Looping is used to execute the statement again and Q.28 What is function ? Why functions are required?
again . (T/F) (CO3) (CO6)
Q.14 Functions in Python will always return a value. (T/F) Q.29 What is module? Write down importance of module
(CO5) in python. (CO6)
Q.15 Give the purpose of print function. (CO5) Q.30 Explain assert statement with example. (CO7)
Q.16 Name two types of scope of variables in Python. Q.31 How you can create a file in Python? Explain with
(CO4) example. (CO8)
Q.17 How many except statement can a try block have? Q.32 Difference between Object-Oriented Programming
(CO7) and Procedural Programming. (CO9)
Q.18 Syntax of creating a class in python is______ (CO9) Q.33 Explain the concept of Greedy Match. (CO10)
Q.19 Define object. (CO9) Q.34 Write down the special character used in regular
Q.20 Write greedy match quantifiers used in Python. expression ? (CO10)
(CO10) Q.35 What is exception and how it is handled in Python?
SECTION-C (CO7)
Note: Short answer type questions. Attempt any twelve SECTION-D
questions out of fifteen questions. (12x5=60) Note: Long answer type questions. Attempt any two
Q.21 Write down key features of Python programming questions out of three questions. (2x10=20)
language? (CO1) Q.36 Write short notes with example on (CO3)
Q.22 Explain any five string functions used in Python. a) for loop
(CO2) b) while loop
Q.23 What are various decision making statement. Give Q.37 Write different ways to pass argument to function
example. (CO3) using example. (CO5)
Q.24 Write a program to print the table of the given Q.38 Explain inheritance and its types with example.
number? (CO3) (CO9)
Q.25 Define list. Explain any four list function. (CO4) (Note: Course outcome/CO is for office use only)
Q.26 Difference between list and tuple. (CO4)
Q.27 Explain Dictionary and how it is created in Python?
(CO1)
(3) 180853/170853 (3680) (4) 180853/170853

You might also like