You are on page 1of 1

Seat No.: ________ Enrolment No.

______________
GUJARAT TECHNOLOGICAL UNIVERSITY
MCA – SEMESTER -II EXAMINATION –WINTER-2021
Subject Code: 629403 Date: 30/12/2021
Subject Name: Programming in Python
Time: 02:30 PM TO 05:00 PM Total Marks: 70
Instructions:
1. Attempt all questions.
2. Make Suitable assumptions wherever necessary.
3. Figures to the right indicate full marks.
Q.1 (a) Do as directed. 07
1. What is recursion?
2. What is GIL?
3. What is Mutable Object ?
4. IDLE stands for ________.
5. What is the difference between extend() and append() methods of list?
6. What is abstract data type?
7. Use of global keyword.
(b) What is module in python? Explain it. 07
Q.2 (a) Explain Tuples, List and Dictionary in detail with suitable example. 07
(b) What is dictionary in Python? Explain with an example. 07
OR
(b) What do you mean by Anonymous function ? Explain map() function with reference to lambda 07
function.
Q.3 (a) Briefly explain file handling in Python? Give the purpose and syntax of the following: open(), 07
close(), read() and write()
(b) Explain Formal and Actual arguments in Python. Also explain the following type of arguments 07
with proper code.
1. Positional Arguments
2. Keyword Arguments
3. Default Arguments
4. Variable Length Arguments
OR
Q.3 (a) What are Exceptions? Write a python code to explain exception handling. 07
(b) What do you mean by Assertion? Explain with example. 07

Q.4 (a) What is the use of MatPlotLib in Python? Explain use of plot(), show() and title() functions of 07
MatPlotLib.
(b) What is polymorphism? Explain method overloading and operator overloading with example. 07
OR
Q.4 (a) What is use of following operations on Data Frames? Explain with a small example of each. - 07
shape - tail() - describe()
(b) What do you mean by Multiple Threading ? Explain use of notify() and wait() methods for 07
thread communication
Q.5 (a) What is a socket? Give the details of various socket methods with appropriate syntax and 07
explanation.
(b) Explain following functions with reference to read the source code from internet and save an 07
image from internet.
- urlopen() - urlretrieve()
OR
Q.5 (a) (1) What is PyLab? Write a simple program of plot using PyLab. 04
(2) Explain the function which is used to retrieve the parts of URL 03
(b) How to insert, update and delete rows into mysql database using python? Write a program to 07
demonstrate all these operations

*************

Page 1 of 1

You might also like