0% found this document useful (0 votes)
51 views4 pages

Introduction To Python Programming 2022 2023

pyton
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
51 views4 pages

Introduction To Python Programming 2022 2023

pyton
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 4

Roll No. …………………..

TCS–201
B. Tech. (CSE) (Second Semester)
EXAMINATION, 2022-23
INTRODUCTION TO PYTHON PROGRAMMING
Time : Three Hours
Maximum Marks : 60
Note : Question paper has three Sections. Read carefully
instructions for each Section.
Section—A
(Very Short Answer Type Questions)

1. Attempt all questions. 1 each


(a) Define encapsulation. (CO1, RE)
(b) Solve the given conversion (101101.100)2 = ( )10.
(CO1, RE)
(c) Write two features of Python programming
language. (CO1, RE)
(d) Illustrate the list slicing in python. (CO2, UN)
(e) Write difference between if-else & switch.
(CO1, RE)

P. T. O.
[2] TCS–201

(f) What is a class ? (CO1, RE)


(g) Explain compile time error. (CO4, RE)
(h) Describe operators in python. (CO1, AN)
(i) Summarize recursive functions. (CO2, UN)
(j) Name different data types in python. (CO4, UN)
(k) Write the difference between compiler and
interpreter. (CO1, AN)
(l) Differentiate between high level and low-level
programming. (CO5, RE)
Section–B
(Short Answer Type Questions)

2. Attempt all questions. 4 each


(a) What is Python ? Explain the various features of
python programming. (CO1, UN)
OR
Define inheritance with suitable example.
(b) Write a program in Python to generate first five
Fibonacci terms using recursive function.
(CO1, RE)
OR
Explain the access modifiers suitable example.
(c) Write a short note on : (CO2, UN)
(i) Pass Statement
(ii) Continue statement
(iii) Break Statement
[3] TCS–201

OR
Write a program in python to check if a given
number by user is an Armstrong number or not.
(d) Illustrate Recursive functions with the help of
suitable example. (CO2, UN)
OR
Write a program in python to print the pattern
given below :
(i) 12345
(ii) 1234
(iii) 123
(iv) 12
(v) 1
(e) Explain the steps to import a module. Also
explain math module and OS module with
example. (CO5, UN)
OR
Define Inheritance and Polymorphism with the
help of example.
(f) What do mean by error handling ? Explain with
suitable example. (CO4, EV)
OR
Define flow control statements with example.

P. T. O.
[4] TCS–201

Section—C
(Long Answer Type Questions)
3. Attempt all questions. 8 each
(a) What are the various features of object-oriented
programming and its advantages ? (CO4, UN)
OR
Describe the program structure and design of
python in detail.
(b) Write a program to check if a given string is
palindrome or not. (CO4, UN)
OR
Explain the different types of function argument.
Explain with suitable example.
(c) Write a short note on : (CO5, UN)
(i) Function Calling
(ii) Pass by Value
OR
Write a program to create a file name
“Dictionary” and write two words “Earth” and
“Technology” to it.

TCS–201

You might also like