Semester : S1 and S2
Year : 2018
Term : JULY
Branch : MECHANICAL ENGINEERING
Scheme : 2015 Full Time
Course Code : BE 101-05
Page:2
21
22
23
24
a)
b)
a)
b)
९)
2)
0)
2)
b)
D1105 Pages: 2
Write a Python program to read the value of n and r and find nCr (n!/(r!*(n-r)!)).
Use a user defined function to find factorial.
Write a Python program to find the sum of first n natural numbers using
recursion.
PART ८
Answer any two full questions, each carries 14 marks
Write a Python program to read two matrices from console, perform addition and
display the resultant matrix. Use list data type for matrix operation.
Describe any four string methods in python with example.
Discuss the different tuple methods in python with example.
Create a dictionary of acc.no and balance of n account holders from console. As
amount is deposited, the balance should increase and as amount is withdrawn the
balance should decrease. Write a program using dictionary datatype in python for
the above.
Explain exception handling in python with example.
Illustrate the need of pickling in python with suitable example.
Create a class “student” having name, age, roll no, mark of three subjects and
total mark as attributes and read (), calculate () and display () as methods. Write a
Python program to read details of a student, find total mark and display the
details.
یلد اد ید بد
Page 2 of 2
(5)
(4)
(2)
(8)
(6)
(6)
(8)