Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
7 views

ICT -1 unit 5 python

Python important questions

Uploaded by

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

ICT -1 unit 5 python

Python important questions

Uploaded by

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

AVS COLLEGE OF TECHNOLOGY, SALEM-106

Department of Science and Humanities


INTENSIVE COACHING TEST-1 (UNIT 5)

Semester & Branch: I &IT ,CSE-A,B, AIDS Duration: 3 Hours Date: 13.12.2024
Subject Code/Name : GE3151& problem solving and python programming
Max. Mark: 100
PART A (10*2=20)
Answer all the Questions
1 How do you delete a file in python?
2 How do you use command line arguments to give input to the programming?
3 Write the significance of format operator.
4 How exceptions are handled in python?
5 What is an exception?
6 What are the two parts in an error message?
7 What is a pickle?
8 Write a note on modular design.
9 What is a package?
10 Find the syntax error in the code given: while True print (‘Hello World’).
PART B (5*16=80)
Answer all the Questions
11 a) i) Write a program to handle the division by zero exception. (8)
ii) Discuss about the math module with example. (8)
Or
b) Write a python program to implement stack operations using modules. (16)
12 a) i) Write a function that copies a file reading and writing up to 50 characters at a time (8)
ii) Write a python program to copying a file. (8)
Or
b) i) Appraise the use of try block and except block in python with example. (6)
ii) Explain with example exceptions with argument in python. (10)
13 a) i) How to merge multiple files to a new file using python. (6)
ii) What are modules in python? How will you import them? Explain the concept
by creating and importing a module. (10)
Or
b)
Name the different access modes for opening a file and present an outline
of the same. (16)
14 a) Discuss about the exception handling using try ,except, raise and finally statements. (16)
Or
b) i) Write a python program to dump objects to a file using pickle. (8)
ii) Illustrate about the command line arguments. (8)
15 a) Mention the commands and their syntax for the following: get current directory,
Changing directory, list, directories and files, make a new directory, renaming
and removing directory. (16)
Or
b)
Discuss about the format operator using functions with examples. (16)

Subject In-Charge HOD IQAC PRINCIPAL

You might also like